How to Pass Variables Into Queries?
Greetings,
I see there is a RAW SQL step within Decisions that I can use to query databases. While this is swell, I would like a way to pass-in variables as parameters in such a query. Is there a way to do this?
Comments
-
Hello!
You can create what's called a Parameterized Query by navigating to Integrations > Databases > {database you wish to connect to} and click "Add Query":
From here, you can type your SQL query and click "Add Parameter" to configure what variable will be used in the query. If connecting to a MS SQL DB, the syntax will look as follows:
Go to the flow you want to use this query in and find the step under Integration > Database > {database you wish to connect to}. From here, you can map-in your variable as an input to the step.
Documentation for setting-up parameterized queries can be found here: https://documentation.decisions.com/docs/parameterized-queries
We hope this helps!
-Gregory, Decisions Support
Howdy, Stranger!
Categories
- 4.5K All Categories
- 86 General
- 13 Training
- 213 Installation / Setup
- 1.2K Flows
- 112 Rules
- 277 Administration
- 215 Portal
- 503 General Q & A
- 722 Forms
- 356 Reports
- 3 Designer Extensions
- 47 Example Flows
- 58 CSS Examples
- 1 Diagram Tile
- 8 Javascript Controls
- 189 Pages
- 5 Process Mining
- New Features
- 187 Datastructures
- 72 Repository
- 237 Integrations
- 30 Multi-Tenant
- 27 SDK
- 81 Modules
- 60 Settings
- 26 Active Directory
- 12 Version 7
- 37 Version 8
- 143 Lunch And Learn Questions