Skip to main content
Version: 2.x

pg_attrdef

The pg_attrdef table in the pg_catalog schema stores column default values. The main information about columns is stored in pg_attribute. Only columns that explicitly specify a default value (when the table is created or the column is added) will have an entry here.

columntypereferencesdescription
oidoidThe object ID
adrelidoidpg_class.oidThe table this column belongs to
adnumsmallintpg_attribute.attnumThe number of the column
adbinpg_node_tree The internal representation of the column default value