PostgresDialectConfig
Config for the PostgreSQL dialect.
interface PostgresDialectConfig {
cursor?: PostgresCursorConstructor;
onCreateConnection?: (connection: DatabaseConnection) => Promise<void>;
pool: PostgresPool | (() => Promise<PostgresPool>);
}§Properties
§
cursor?: PostgresCursorConstructor
[src]https://github.com/brianc/node-postgres/tree/master/packages/pg-cursor
import Cursor from 'pg-cursor'
// or
import * as Cursor from 'pg-cursor'
new PostgresDialect({
cursor: Cursor
})
§
onCreateConnection?: (connection: DatabaseConnection) => Promise<void>
[src]Called once for each created connection.
§
pool: PostgresPool | (() => Promise<PostgresPool>)
[src]A postgres Pool instance or a function that returns one.
If a function is provided, it's called once when the first query is executed.