Query Editor
  • 11 Mar 2024
  • 2 Minutes to read
  • Dark
    Light

Query Editor

  • Dark
    Light

Article Summary

The Query Editor allows users to write queries against any established database connection. These queries can be saved for future use and are available for quick access. The results of any query can be downloaded and saved as a CSV file.

Enable/Disable Query Editor for Designers

The option Allow Designers to Use Query Editor under System > Settings > Designer Studio Settings > QUERY EDITOR permits all Designer users to access the Query Editor and the ability to execute queries if they are checked.


Accessing the Query Editor

The Query Editor can be found by right-clicking any Designer Project Folder and selecting Other > Query Editor.


Using the Query Editor

To ensure that data is not caught in the cache, changes in the Query Editor should be followed by a service restart.

  1. Selecting Query Editor will open the New Database Query window. The Connection drop-down menu on the right side of the window allows the user to choose any established database connection. 

  2. In the search bar, enter "entity_account" to search the database connection for the entity_account Table. To inspect the Table schema, expand the list by clicking to the left of the Table name.
     

  3. Generate a query on the table by selecting a query on the action menu when hovering over a Table. In the entity_account action menu, select Generate "Select" Query.
     

    As the Query Editor allows the ability to perform queries on Tables within a selected database, SQL Queries may also be generated manually by providing them as text input in the box on the left-hand side and then clicking RUN.

  4. On the left-hand panel, click RUN.

  5. After the query runs, users can export the results to a CSV file by clicking Download as CSV. Users can save the query for future use by clicking SAVE, naming the query, and selecting Save if desired.

  6. In the Designer Project, users can see saved queries and re-run them via the action menu.
     

All Queries Report

All queries in the query editor are saved to a centralized location and accessed in a Report Format. This Report is accessible at System > Integration > Database Queries.

Actions to perform on Queries:

Right-clicking on the query allows a bunch of actions to be performed on the query. Refer to the following table:

Actions

Description

Edit Database Query

Allows users to edit the query.

Add > Setup > Manage Tags

Allow users to add a tag to the query.

Auto Run > Create Interval Flow

Auto Run > Create Scheduled Job Flow
Auto Run > Create Startup Flow

Clicking on any of the options creates automated jobs in the respective job type. These jobs can be found at System > Jobs and Events > Scheduled Jobs. For more information, refer to Understanding Scheduled Jobs.

Auto Run > Enable Run on Import

When the query is imported to the platform, it will run immediately.

Dependencies

Allows users to browse, manage, and declare dependency.

Designer Repository

Allows to perform repository actions.

Import/Export

Allows to import and export the query.

Manage

Allows users to perform various actions such as Delete, Get Query ID, Move, and view History and Entity Details of the Query.


For further information on Administration, visit the Decisions Forum.


Was this article helpful?