Redrock Postgres Search Chinese
Version: 9.3 / 9.4 / 9.5 / 9.6 / 10 / 11 / 12 / 13 / 14 / 15 / 16

51.6. pg_attrdef

The catalog pg_attrdef stores column default values. The main information about columns is stored in pg_attribute. Only columns for which a default value has been explicitly set will have an entry here.

Table 51.6. pg_attrdef Columns

NameTypeReferencesDescription
oidoid Row identifier
adrelidoidpg_class.oidThe table this column belongs to
adnumint2pg_attribute.attnumThe number of the column
adbinpg_node_tree The column default value, in nodeToString() representation. Use pg_get_expr(adbin, adrelid) to convert it to an SQL expression.