Database Select
Database Select runs a SQL SELECT against an external database
(PostgreSQL, MySQL/MariaDB or SQL Server) and emits the matching
rows as a JSON array. For everything that is not a SELECT (DDL,
INSERT, UPDATE, DELETE) use
Database Execute. You find it on the node
picker’s Storage shelf.
The node connects with a secret of type Database credentials. Create one under Connections → Secrets first; see Secrets.
Configuration
Section titled “Configuration”

| Field | Type | Default | Description |
|---|---|---|---|
Secret credential (secretCredentialId) | string ✦ (required) | — | The database credentials to connect with, chosen from your secrets. |
Extra credentials (extraCredentials) | key-value map (optional) | — | Extra connection settings merged on top of the chosen secret’s config. |
Query (query) | string ✦ (required) | — | The SELECT query to run; the matching rows are returned as the node output. |
Parameters (parameters) | key-value map (optional) | — | Named parameters bound into the query’s placeholders. |
Fields marked ✦ accept expressions.
Try this node — run it once against your own workspace, with your credentials, without building a flow first.
extraCredentials entries are merged into the connection config as
written and are not expression-resolved, so a flow cannot pick its
database server from the payload it was started with. Use a separate
secret per server instead. To choose the credentials at runtime, switch
the credentials field to expression mode and resolve the id of a
credential secret from flow data.
Output
Section titled “Output”The node emits a JSON array of row objects:
[ { "id": 1, "name": "Alice", "email": "alice@example.com" }, { "id": 2, "name": "Bob", "email": "bob@example.com" }]An empty result set returns [].
An Agent can call this node as a tool; as a read-only tool it runs without pausing for approval.
Example
Section titled “Example”The Database / Select template in the
template gallery creates a smoke_customers
table, seeds a row, and selects it back with a bound parameter:
SELECT id, name, email FROM smoke_customers WHERE id = :idparameters: id → {{ $prev->id }}Related
Section titled “Related”- Database Execute runs statements that do not return rows.
- Database Insert and Database Upsert write rows without hand-written SQL.
- Table Store Query is the same query against a built-in table store.
- Use an external database walks through the credential setup.