pg_config (view)

A system catalogue view describing the compile-time configuration parameters of the current PostgreSQL instance

pg_config is a system catalogue view which describes the compile-time configuration parameters of the current PostgreSQL instance - basically providing the output of the pg_config utility via the SQL interface.

Note that the unfiltered output appears to be in a predictable order, namely the same as the pg_config utility output.

pg_config was introduced in PostgreSQL 9.6 (commit: a5c43b88.)

Definition by PostgreSQL version

pg_config (PostgreSQL 13)

           View "pg_catalog.pg_config"
 Column  | Type | Collation | Nullable | Default
---------+------+-----------+----------+---------
 name    | text |           |          |
 setting | text |           |          |
    

Documentation: pg_config

pg_config (PostgreSQL 12)

           View "pg_catalog.pg_config"
 Column  | Type | Collation | Nullable | Default
---------+------+-----------+----------+---------
 name    | text |           |          |
 setting | text |           |          |
    

Documentation: pg_config

pg_config (PostgreSQL 11)

           View "pg_catalog.pg_config"
 Column  | Type | Collation | Nullable | Default
---------+------+-----------+----------+---------
 name    | text |           |          |
 setting | text |           |          |
    

Documentation: pg_config

pg_config (PostgreSQL 10)

           View "pg_catalog.pg_config"
 Column  | Type | Collation | Nullable | Default
---------+------+-----------+----------+---------
 name    | text |           |          |
 setting | text |           |          |
    

Documentation: pg_config

pg_config (PostgreSQL 9.6)

View "pg_catalog.pg_config"
 Column  | Type | Modifiers
---------+------+-----------
 name    | text |
 setting | text |
    

Documentation: pg_config

Change history

Examples

postgres=# SELECT * FROM pg_config;
       name        |                                                                                              setting
 -------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
 BINDIR            | /home/pguser/postgres/builds/96/bin
 DOCDIR            | /home/pguser/postgres/builds/96/share/doc
 HTMLDIR           | /home/pguser/postgres/builds/96/share/doc
 INCLUDEDIR        | /home/pguser/postgres/builds/96/include
 PKGINCLUDEDIR     | /home/pguser/postgres/builds/96/include
 INCLUDEDIR-SERVER | /home/pguser/postgres/builds/96/include/server
 LIBDIR            | /home/pguser/postgres/builds/96/lib
 PKGLIBDIR         | /home/pguser/postgres/builds/96/lib
 LOCALEDIR         | /home/pguser/postgres/builds/96/share/locale
 MANDIR            | /home/pguser/postgres/builds/96/share/man
 SHAREDIR          | /home/pguser/postgres/builds/96/share
 SYSCONFDIR        | /home/pguser/postgres/builds/96/etc
 PGXS              | /home/pguser/postgres/builds/96/lib/pgxs/src/makefiles/pgxs.mk
 CONFIGURE         | '--prefix=/home/pguser/postgres/builds/96' 'LDFLAGS=-L/opt/local/lib'
 CC                | gcc
 CPPFLAGS          | -DFRONTEND
 CFLAGS            | -Wall -Wmissing-prototypes -Wpointer-arith -Wdeclaration-after-statement -Wendif-labels -Wmissing-format-attribute -Wformat-security -fno-strict-aliasing -fwrapv -fexcess-precision=standard -O2
 CFLAGS_SL         |
 LDFLAGS           | -L../../src/common -L/opt/local/lib -Wl,-dead_strip_dylibs
 LDFLAGS_EX        |
 LDFLAGS_SL        |
 LIBS              | -lpgcommon -lpgport -lz -lreadline -lm
 VERSION           | PostgreSQL 9.6.6
(23 rows)

Categories

PostgreSQL internals, System catalogue

See also

pg_config