Module

x/kysely_postgrs_js_dialect/mod.ts>kysely.PostgresDialectConfig

Kysely dialect for PostgreSQL using the Postgres.js client.
interface kysely.PostgresDialectConfig
import { type kysely } from "https://dotland.deno.dev/x/kysely_postgrs_js_dialect@v0.27.3/mod.ts";
const { PostgresDialectConfig } = kysely;

Config for the PostgreSQL dialect.

Properties

pool: PostgresPool | (() => Promise<PostgresPool>)

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.

https://node-postgres.com/apis/pool

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
})
optional
onCreateConnection: (connection: DatabaseConnection) => Promise<void>

Called once for each created connection.

import kysely.PostgresDialectConfig
import { kysely } from "https://dotland.deno.dev/x/kysely_postgrs_js_dialect@v0.27.3/mod.ts";
const { PostgresDialectConfig } = kysely;