core.sql.execute_query
Execute a parameterized SQL query on an external database.
Secrets
Required secrets:sql: required valuesCONNECTION_URL.
Inputs
SQL query to execute. Use :param_name syntax for bound parameters. Do NOT use Tracecat expressions in the query string.
Bound query parameters as a dictionary (injected with :param_name syntax). Supply dynamic values here, NOT within the query string. This is required for safe, parameterized SQL queries.Default:
null.Return a single row instead of a list of rows. Defaults to False, which fetches all rows.Default:
false.Maximum number of rows to return. Default 200. Prevents accidentally returning huge result sets.Default:
200.Examples
Query an external databasecore.duckdb.execute_sql
Execute SQL in an in-process DuckDB engine
Inputs
SQL to execute in an in-process DuckDB connection.