PostgreSQL Connector (Single Row)
This template demonstrates how to integrate a PostgreSQL Database as a live data source within a Decision Flow. It specifically shows how to use the DB Single Row node, how to pass variables to the SQL query, and how to fetch data from the database and propagate it into the flow’s output.
David Škarka
Template author
- DB Single Row Node (postgresql_single_row):
- Function: Connects to the database using the connector alias conn-postgresql-templates.
- Logic: Executes the SQL statement.
Constraint: This node is designed to return exactly one row. For multiple rows, use a standard database node instead.
- Data Manipulation Node (assign):
- Function: Extracts the result from the database node.
- Logic: Maps the value found at postgresql_single_row.row to the final output.
- Prerequisite: Ensure your PostgreSQL DB instance is accessible from the DecisionRules backend (Cloud or On-Premise).
- Setup: Create a Database Connector in the Space settings with the specific alias conn-postgresql-templates.
- More details could be found in the main flow description - in the Flow Designer, select in the Sidebar the Rule Settings and scroll down to Description
More Templates
See Other Templates
Pruebas A/B
Descubra una forma sencilla de asignar un grupo de prueba para realizar pruebas A/B en sus decisiones.
Precios basados en el riesgo
Descubra una forma sencilla de aplicar una matriz de precios basada en riesgo adecuada en función del tipo de cliente.
Normas de elegibilidad y política
Descubra una forma sencilla de definir y ejecutar varios conjuntos de reglas y obtener el resultado de la decisión final.