← PostgreSQL

Find Row with PostgreSQL API

Pipedream makes it easy to connect APIs for PostgreSQL and 900+ other apps remarkably fast.

Trigger workflow on
HTTP requests, schedules and app events
Next, do this
Find Row with the PostgreSQL API
No credit card required
Into to Pipedream
Watch us build a workflow
Watch us build a workflow
7 min
Watch now ➜
Trusted by 250,000+ developers from startups to Fortune 500 companies:
Trusted by 250,000+ developers from startups to Fortune 500 companies

Developers Pipedream

Getting Started

Create a workflow to Find Row with the PostgreSQL API. When you configure and deploy the workflow, it will run on Pipedream's servers 24x7 for free.

  1. Configure the Find Row action
    1. Connect your PostgreSQL account
    2. Select a Schema
    3. Select a Table
    4. Select a Lookup Column
    5. Select a Lookup Value
    6. Optional- Configure Reject Unauthorized
  2. Select a trigger to run your workflow on HTTP requests, schedules or app events
  3. Deploy the workflow
  4. Send a test event to validate your setup
  5. Turn on the trigger

Integrations

Find Row with PostgreSQL API on New Requests (Payload Only) from HTTP / Webhook API
HTTP / Webhook + PostgreSQL
 
Try it
Find Row with PostgreSQL API on New Item in Feed from RSS API
RSS + PostgreSQL
 
Try it
Find Row with PostgreSQL API on New Message from Discord API
Discord + PostgreSQL
 
Try it
Find Row with PostgreSQL API on New Message In Channels from Slack API
Slack + PostgreSQL
 
Try it
Find Row with PostgreSQL API on New Message in Channel from Discord Bot API
Discord Bot + PostgreSQL
 
Try it

Details

This is a pre-built, open source component from Pipedream's GitHub repo. The component is developed by Pipedream and the community, and verified and maintained by Pipedream.

To contribute an update to an existing component or create a new component, create a PR on GitHub. If you're new to Pipedream component development, you can start with quickstarts for trigger span and action development, and then review the component API reference.

Find Row on PostgreSQL
Description:Finds a row in a table via a lookup column. [See Docs](https://node-postgres.com/features/queries)
Version:0.0.6
Key:postgresql-find-row

Code

import postgresql from "../../postgresql.app.mjs";

export default {
  name: "Find Row",
  key: "postgresql-find-row",
  description: "Finds a row in a table via a lookup column. [See Docs](https://node-postgres.com/features/queries)",
  version: "0.0.6",
  type: "action",
  props: {
    postgresql,
    schema: {
      propDefinition: [
        postgresql,
        "schema",
      ],
    },
    table: {
      propDefinition: [
        postgresql,
        "table",
        (c) => ({
          schema: c.schema,
        }),
      ],
    },
    column: {
      propDefinition: [
        postgresql,
        "column",
        (c) => ({
          table: c.table,
          schema: c.schema,
        }),
      ],
      label: "Lookup Column",
      description: "Find row by searching for a value in this column. Returns first row found",
    },
    value: {
      propDefinition: [
        postgresql,
        "value",
        (c) => ({
          table: c.table,
          column: c.column,
          schema: c.schema,
        }),
      ],
    },
    rejectUnauthorized: {
      propDefinition: [
        postgresql,
        "rejectUnauthorized",
      ],
    },
  },
  async run({ $ }) {
    const {
      schema,
      table,
      column,
      value,
      rejectUnauthorized,
    } = this;
    try {
      const res = await this.postgresql.findRowByValue(
        schema,
        table,
        column,
        value,
        rejectUnauthorized,
      );
      const summary = res
        ? "Row found"
        : "Row not found";
      $.export("$summary", summary);
      return res;
    } catch (error) {
      throw new Error(`
      Row not retrieved due to an error. ${error}.
      This could be because SSL verification failed, consider changing the Reject Unauthorized prop and try again.
    `);
    }
  },
};

Configuration

This component may be configured based on the props defined in the component code. Pipedream automatically prompts for input values in the UI and CLI.
LabelPropTypeDescription
PostgreSQLpostgresqlappThis component uses the PostgreSQL app.
SchemaschemastringSelect a value from the drop down menu.
TabletablestringSelect a value from the drop down menu.
Lookup ColumncolumnstringSelect a value from the drop down menu.
Lookup ValuevaluestringSelect a value from the drop down menu.
Reject UnauthorizedrejectUnauthorizedboolean

If not false, the server certificate is verified against the list of supplied CAs. An 'error' event is emitted if verification fails

Authentication

PostgreSQL uses API keys for authentication. When you connect your PostgreSQL account, Pipedream securely stores the keys so you can easily authenticate to PostgreSQL APIs in both code and no-code steps.

Before you connect to your PostgreSQL database from Pipedream, please make sure your database is either:

  1. Accessible from the public internet (You may need to add a firewall rule on 0.0.0.0/0 on port 3306), or

  2. Accessible from an SSH server that you route PostgreSQL requests through

After that, enter the following values:

  • host: The hostname or IP address of your PostgreSQL server
  • port: 3306, unless you run PostgreSQL on a different port
  • username: The account username to log in
  • password: The account password to log in
  • database: The name of the PostgreSQL database to run queries against

About PostgreSQL

The World's Most Advanced Open Source Relational Database

More Ways to Use PostgreSQL

Triggers

New Column from the PostgreSQL API

Emit new event when a new column is added to a table. See Docs

 
Try it
New or Updated Row from the PostgreSQL API

Emit new event when a row is added or modified. See Docs

 
Try it
New Row from the PostgreSQL API

Emit new event when a new row is added to a table. See Docs

 
Try it
New Row Custom Query from the PostgreSQL API

Emit new event when new rows are returned from a custom query that you provide. See Docs

 
Try it
New Table from the PostgreSQL API

Emit new event when a new table is added to the database. See Docs

 
Try it

Actions

Delete Row(s) with the PostgreSQL API

Deletes a row or rows from a table. See Docs

 
Try it
Execute Custom Query with the PostgreSQL API

Executes a custom query you provide. See Docs

 
Try it
Find Row With Custom Query with the PostgreSQL API

Finds a row in a table via a custom query. See Docs

 
Try it
Insert Row with the PostgreSQL API

Adds a new row. See Docs

 
Try it
Update Row with the PostgreSQL API

Updates an existing row. See Docs

 
Try it