Documentation - v0.29.1
    Preparing search index...

    Interface PgClient

    Minimal interface for a pg-compatible client. Satisfied by pg.Pool, pg.Client, and pg.PoolClient, as well as PGlite.

    interface PgClient {
        close?(): MaybePromise<void>;
        end?(): MaybePromise<void>;
        query<T>(query: string, values?: unknown[]): Promise<{ rows: T[] }>;
        release?(): MaybePromise<void>;
    }
    Index

    Methods

    • Type Parameters

      • T

      Parameters

      • query: string
      • Optionalvalues: unknown[]

      Returns Promise<{ rows: T[] }>