MCPcopy
hub / github.com/jackc/pgx / ParseConfig

Function ParseConfig

conn.go:238–240  ·  view source on GitHub ↗

ParseConfig creates a ConnConfig from a connection string. ParseConfig handles all options that [pgconn.ParseConfig] does. In addition, it accepts the following options: - default_query_exec_mode. Possible values: "cache_statement", "cache_describe", "describe_exec", "exec", and "simple_protocol".

(connString string)

Source from the content-addressed store, hash-verified

236// The maximum size of the description cache used when executing a query with "cache_describe" query exec mode.
237// Default: 512.
238func ParseConfig(connString string) (*ConnConfig, error) {
239 return ParseConfigWithOptions(connString, ParseConfigOptions{})
240}
241
242// connect connects to a database. connect takes ownership of config. The caller must not use or access it again.
243func connect(ctx context.Context, config *ConnConfig) (c *Conn, err error) {

Callers 2

mustParseConfigFunction · 0.70
ConnectFunction · 0.70

Calls 1

ParseConfigWithOptionsFunction · 0.70

Tested by 1

mustParseConfigFunction · 0.56