Docs
NodesDatabase Nodes
Edit Page on GitHub

PostgreSQL - Query Rows

Query postgres database

postgresdatabasequeryHard5
PostgreSQL - Query Rows Node Screenshot

Description

The PostgreSQL - Query Rows node allows you to query rows from a PostgreSQL database based on specified conditions.

Common Use Cases

  • Retrieve user data based on specific criteria
  • Fetch records for reporting or analysis
  • Get configuration settings stored in the database

Inputs

The input connections this node accepts:

NameDescriptionTypeFlowThe flow of the workflowFlowTableName of the table to queryTextColumnsComma-separated columns to select (or * for all)TextWhereClauseThe WHERE clause with placeholders ($1, $2, etc.)TextWhereValuesArray of values for the WHERE clause (e.g., [123, 'active'])Text[]LimitThe maximum number of rows to returnNumber

Outputs

The output connections this node provides:

NameDescriptionTyperowsThe array of rows returned by the queryJSONrowCountThe number of rows returnedNumberToolThe tool version of this node, to be used by LLMsTool

Fields

The configurable fields this node provides:

NameDescriptionTypeTableName of the table to queryValue: usersTextColumnsComma-separated columns to select (or * for all)Value: *TextWhereClauseThe WHERE clause with placeholders ($1, $2, etc.)Value: id = $1TextWhereValuesArray of values for the WHERE clause (e.g., [123, 'active'])Value: Enter values here...Text[]LimitThe maximum number of rows to returnValue: 10NumberPG_CONNECTION_STRINGPostgres connection stringDefaultValue: postgres://user:password@localhost:5432/dbnameenv

Last updated on