Skip to main content

ClientConfiguration

The configuration object passed to new SqbClient(config). See Creating a Client for the full guide, including the dialect/driver resolution rules.

interface ClientConfiguration {
dialect?: string;
driver?: string;
name?: string;
host?: string;
port?: number;
user?: string;
password?: string;
database?: string;
schema?: string;
driverOptions?: any;
pool?: PoolConfiguration;
defaults?: ClientDefaults;
}
FieldTypeDescription
dialectstringSQL dialect to resolve a registered Adapter for. One of dialect/driver is required.
driverstringDriver package name to resolve a registered Adapter for. One of dialect/driver is required.
namestringAn arbitrary connection name.
hoststringDatabase server address.
portnumberDatabase listener port.
userstringDatabase username.
passwordstringDatabase password.
databasestringDatabase name.
schemastringDatabase schema to use — see Schemas.
driverOptionsanyExtra options passed straight through to the underlying driver.
poolPoolConfigurationConnection pool tuning.
defaultsClientDefaultsDefault values applied to every query executed through this client.