pg_db_role_setting — PostgreSQL system catalog

The PostgreSQL pg_db_role_setting system catalog: full column reference (names, types, descriptions), catalog relationships and version support.

Summary

The catalog pg_db_role_setting records the default values that have been set for run-time configuration variables, for each role and database combination.

(Description quoted from the official PostgreSQL documentation.)

Columns

The pg_db_role_setting system catalog exposes the following columns (names, types and descriptions are taken verbatim from the PostgreSQL documentation):

  • setdatabase oid references pg_database.oid
    The OID of the database the setting is applicable to, or zero if not database-specific
  • setrole oid references pg_authid.oid
    The OID of the role the setting is applicable to, or zero if not role-specific
  • setconfig text[]
    Defaults for run-time configuration variables

Related catalogs

This object references the following other system catalogs:

Version applicability

Present in PostgreSQL 17, 18, 19 (verified against each release’s documentation). This is a long-standing system object that also exists in earlier PostgreSQL releases.

Related & references

Reference: PostgreSQL documentation — pg_db_role_setting.