search cancel

How to extract the query from a report or filter

book

Article ID: 256393

calendar_today

Updated On:

Products

IT Management Suite

Issue/Introduction

The customer wants to access the SQL query used for an existing report or filter to use as an example to create his own.

Environment

ITMS 8.5, 8.6

Resolution

There are a couple of ways that you can see the SQL query used:

  1. Most default reports have the "Edit" option grayed out. If you clone the report or filter, it should be available to you to click on it. 



    After clicking on "Edit", you should see the "Resolved Query" tab.  This tab will have the SQL query that is used for that report. 




  2. Usually, any SQL query used in our reports or filters can be displayed if you right-click on the report and select "view as xml"



  3. or if you export it and open the XML,




    you should see a <query> section:

 

Most reports or filters are straight forward with their queries. Others may use functions or stored procedures to grab the data needed for the report.

Attachments