Go to the latest v7.6 documentation →
Query
Query is a part of QUERY STUDIO module. Using Query, users can execute single or multiple SQL Queries by selecting the desired data source profile. Users can also add a Variable and run queries accordingly.
To learn about Query, let us walk through the below procedure:
- Click the QUERY STUDIO tab.
- Hover on the ‘Query Builder’ snippet from the left pane options.
- Click the ‘Query’ option.
Note: Users can click the ‘Query’ from left pane options. Users can also directly click the ‘New Query’ button icon or ‘New Query’ text as a drop-down selection.
Path 01: QUERY STUDIO > Query Builder > Query
Path 02: QUERY STUDIO > New Query
- A new ‘Query’ session page is displayed.
- A drop-down list is available to select the desired profile from the ‘profile’ option.
- A ‘Refresh Profile’ button is used to refresh the ‘profile’ session.
- A plus (+) button (New Profile) is used to add a new profile.
Note: click here for the ‘New Profile’ creation user guide.
- Let’s suppose select ‘RD Metadata’ from the Profile drop-down selection.
Note: All user created profiles are visible under this ‘Profile’ drop-down selection option.
- A toggle switch selection in between ‘SQL Query/Visual Query’ is displayed.
Note: By default, the toggle is enabled to ‘SQL Query’ option. If the ‘SQL Query’ is enabled, then the user can drag a specific SQL Query with the help of a navigator from the schemas and tables. If the user enables the ‘Visual Query’ option, then the visual Metadata columns and Data are displayed in a tabular format.
- A ‘Navigator’ button is present towards the top right side of the console.
- Click the ‘Navigator’ button.
- A ‘Navigator’ slide page is displayed.
- Select the ‘dbo._MigrationHistory’.
Navigator Path: RD_metadata > RDMetaData > dbo._MigrationHistory
- Clicking the ‘dbo._MigrationHistory’ will add a Custom Query.
Note: As the user adds a Custom Query, all the buttons (Compile, Pretty Print, New Query, Save, Execute Now, and Show Variables) are enabled by default.
- Let’s suppose click the ‘Compile’ button.
- A message ‘Compile successful!’ is displayed.
- Let’s suppose click the ‘Pretty Print’ button.
- The Custom Query SQL is displayed in ‘Pretty Print’ view pattern.
- Let’s suppose click the plus (+) (New Query) button.
- The user is navigated to a ‘New Query’ session page.
Note: Close this window and navigate back to the previous main ‘Query’ session page.
- Click the ‘Show Variables’ button.
- A ‘Variables’ pop-up window is displayed displaying different tabs such as Predefined variables, User defined variables, and Predefined functions.
Note: By default, ‘Predefined variables’ tab is selected.
- Clicking the ‘Predefined functions’ displays Predefined functions tabular grid with Name and Description columns.
- Clicking the ‘User defines variables’ tab displays a tabular grid with Variable Name and Description columns.
- Click the plus ‘(+) New Variable’ button at the top right side.
- The user is navigated to the ‘Variable Builder’ session page.
Note: click here for more info on ‘Variable Builder’ (Variable Explorer) user guide.
Note: Close this window and navigate back to the ‘Query’ session page.
- Click the ‘Execute Now’ button.
- The Query execution takes place displaying the ‘Results’ tab tabular grid data.
- A ‘Min View’ button is used to display the minimum view pattern.
- A ‘Max View’ button is used to display the maximum view pattern.
- An ‘Export to CSV’ button is used to download the Query execution results into a CSV file.
- A ‘Search’ box is used to search for any contents from the Query execution results tab tabular grid.
- Click the ‘Save’ button to save this executed Query.
- An ‘Additional saving options’ pop-up window is displayed.
- Let’s suppose add ‘RD Meatadata Query execution’ under the ‘Query Name’ text field.
- Click the ‘Save’ button.
- A message ‘RD Meatadata Query execution saved successfully!’ is displayed.
- As the user saves the Query, two texts namely ‘Query Version: Executable’ and ‘Query Name: RD Meatadata Query execution’ are displayed.
- A ‘Where Used List’ button is displayed besides the ‘Query Name: RD Meatadata Query execution’ text.
- Hovering on the ‘Query Name’ text field displays ‘Click to Change Query Name’ info.
- Let’s suppose, click on the ‘Click to Change Query Name’
- If the user wishes to change the ‘Query Name’ then it can be done from here.
- Clicking the green tick mark updates the changes with the new ‘Query Name.
- Clicking the ‘x’ button closes the editable text pattern without making any changes in the ‘Query Name.’
- A ‘Where Used List’ pop-up window is displayed.
Note: ‘Where Used List’ info let users know if any created Query is being run in FDRs, Validations, Query Chains, or Jobs by other users.
Note: By default, FDR tab is selected.
Note: Close this window and navigate back to the ‘Query’ session page.
- Click the ‘Query Studio’ module to check this created Query (RD Meatadata Query execution) within the ‘Query Explorer’ session page.
- A ‘Query Explorer’ session page is displayed.
- Let’s enter the created ‘Query Name’ (RD Meatadata Query execution) in the ‘Search’ box field.
- Click the ‘Search’ icon button.
- The ‘RD Meatadata Query execution’ Query Name is displayed.