Skip to content

Execute Query

Description

The Execute Query activity allows users to execute SQL queries on files or data stored in a connected data source (e.g., database, storage, or file-based system).
This activity supports dynamic queries, and optionally allows saving the results to files with encryption, formatting, and custom output configuration.

Use this activity to:

  • Execute ad hoc or parameterized SQL queries on uploaded or connected data
  • Retrieve transformed or filtered data for further processing
  • Generate reports or structured data files from query results

Use Case:
Useful in scenarios where data needs to be filtered, joined, aggregated, or reshaped before it’s used in reporting, validation, or export.


Input

TypeDescription
FilesFiles/data available in the connection

Output

TypeFormatDescription
Data / FileTable / FileQuery result as a table or downloadable file

Configuration Fields

Field NameRequiredDescription
ConnectionYesConnection to the data source where the query should be executed.
QueryYesSQL query to be executed on the connected data source.
Save As FileNoIf enabled, the query result will be saved as a file.
Secret KeyConditionalEncryption key used to secure the generated output file (enabled only if Save As File is true).
File PatternConditionalPattern for naming the generated files.
Sheet NameConditionalSheet name to use in the generated file (for Excel formats).
FileConditionalTemplate file to structure the output.
Split by ColumnConditionalColumn name used to split the query result into multiple output files.
Starting RowConditionalRow index in the template file from where data insertion begins.
Starting ColumnConditionalColumn index in the template file from where data insertion begins.

Sample Input

Not applicable — data is pulled from the connected data source.


Sample Configuration

FieldValue
ConnectionAzureBlobConnection
QuerySELECT * FROM SalesData WHERE Region = 'East'
Save As Filetrue
Secret KeyEncrypt@123
File PatternSales_Report_[Region]
Sheet NameEastRegionSales
Split by ColumnRegion
Starting Row2
Starting ColumnB

Sample Output

CustomerProductRegionAmount
JohnLaptopEast1200
AlicePrinterEast400

If “Save As File” is enabled, this output will be saved in the specified file format.