pg_parameter_status — Get the value of a parameter from the database server
pg_parameter_statusconn
paramName
pg_parameter_status
returns the value of a
PostgreSQL parameter as supplied by the server.
Different releases of PostgreSQL may provide different parameters.
As of PostgreSQL-8.4.0, the following parameters are available.
Parameter | Description | Example Value |
---|---|---|
client_encoding | Client's character set encoding | SQL_ASCII or UNICODE |
DateStyle | Display format and rules for ambiguous date/time values | ISO, MDY |
integer_datetimes | Date/times are integer based | off |
IntervalStyle | Display format and rules for interval types | postgres |
is_superuser | Has superuser rights? | off |
server_encoding | Server (database) character set encoding | SQL_ASCII or UNICODE |
server_version | PostgreSQL server version | 8.4.0 |
session_authorization | Username | guest |
standard_conforming_strings | Backslash \ is literal in quoted strings | off |
TimeZone | Time zone for displaying and interpreting time stamps | EST5EDT |
conn
The handle of the connection.
paramName
The name of the parameter to get. See above list.
The value of the parameter, or an empty string if no such parameter was supplied by the database.
This command does not contact the database server. Parameters are supplied by the server at connection time (or possibly later) and saved by the interface until needed.
For another way to access the server version, see pg_server_version.
This command uses or emulates the PostgreSQL
libpq
function PQparameterStatus
.
This version of the manual was produced for the
Pgtcl-ng Sourceforge project web service site, which requires the logo on each
page.
To download a logo-free copy of the manual, see the
Pgtcl-ng project
downloads area.