Adding a Query to External Database
- 16 Jun 2021
- 1 Minute to read
- Print
- DarkLight
This documentation version is deprecated, please click here for the latest version.
Adding a Query to External Database
- Updated on 16 Jun 2021
- 1 Minute to read
- Print
- DarkLight
Article summary
Did you find this summary helpful?
Thank you for your feedback
Overview
Decisions allows users to add a query to an existing Database Connection during the Database Integration set up, or after set up by using the functions found in the 'Databases' folder; utilizing any of these folder actions like adding Queries, Procedures, Tables, and views to a Database creates Flow steps for use in the Flow Designer. This method for retrieving data from the database is most often used to speed up load times for large collections of data.
Example
- To demonstrate this process of adding a query, the LOCAL CONNECTION database will be used due to it being on all Decisions instances.
- Navigate to the integrated database under System > Integrations > Databases. Right-click LOCAL CONNECTION and select Add Query.
- Enter a name for the query, representing its purpose (the name cannot contain spaces).
- In the Query field, add the query. If the query returns data, check the Returns Data checkbox. It is not necessary to add a semicolon to the end of the query.
- If a count attribute of the result set is desired, click the Output Count checkbox. If there is a need to limit the number of records returned, click the Limit Data checkbox and set the number of records.
- Click on RUN QUERY to test the query.
- The Results tab appears showing the data returned (if the query returns data). The Dynamic Type tab shows the data structure of the data returned.
- Click OK to save the query.
- Now, in the Flow Designer, under the components for the database, a component for running this query will be available.
Was this article helpful?