From 120139a206078c030cdab77ee1d05984bb503fe5 Mon Sep 17 00:00:00 2001 From: Jack Christensen Date: Thu, 14 Jan 2021 18:22:18 -0600 Subject: [PATCH] Add link to PG docs for connString format fixes #62 --- config.go | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/config.go b/config.go index e4ee244a..38e94f26 100644 --- a/config.go +++ b/config.go @@ -112,9 +112,10 @@ func NetworkAddress(host string, port uint16) (network, address string) { } // ParseConfig builds a *Config with similar behavior to the PostgreSQL standard C library libpq. It uses the same -// defaults as libpq (e.g. port=5432) and understands most PG* environment variables. connString may be a URL or a DSN. -// It also may be empty to only read from the environment. If a password is not supplied it will attempt to read the -// .pgpass file. +// defaults as libpq (e.g. port=5432) and understands most PG* environment variables. ParseConfig closely matches +// the parsing behavior of libpq. connString may either be in URL format or keyword = value format (DSN style). See +// https://www.postgresql.org/docs/current/libpq-connect.html#LIBPQ-CONNSTRING for details. connString also may be +// empty to only read from the environment. If a password is not supplied it will attempt to read the .pgpass file. // // # Example DSN // user=jack password=secret host=pg.example.com port=5432 dbname=mydb sslmode=verify-ca