PostgreSQL 14 ← 13
SYSTEM CATALOG · System catalog
pg_partitioned_table
The catalog pg_partitioned_table stores information about how tables are partitioned.
Checked column by column against a PostgreSQL 18.6 instance · Raw measurement record ↗
Columns PostgreSQL 18
pg_partitioned_table| COLUMN | TYPE | DESCRIPTION |
|---|---|---|
partrelid |
oidNOT NULL |
The OID of the pg_class entry for this partitioned tableReferences:pg_class.oid |
partstrat |
"char"NOT NULLDocumented as:char |
Partitioning strategy; h = hash partitioned table, l = list partitioned table, r = range partitioned table |
partnatts |
smallintNOT NULLDocumented as:int2 |
The number of columns in the partition key |
partdefid |
oidNOT NULL |
The OID of the pg_class entry for the default partition of this partitioned table, or zero if this partitioned table does not have a default partitionReferences:pg_class.oid |
partattrs |
int2vectorNOT NULL |
This is an array of partnatts values that indicate which table columns are part of the partition key. For example, a value of 1 3 would mean that the first and the third table columns make up the partition key. A zero in this array indicates that the corresponding partition key column is an expression, rather than a simple column reference.References:pg_attribute.attnum |
partclass |
oidvectorNOT NULL |
For each column in the partition key, this contains the OID of the operator class to use. See pg_opclass for details.References:pg_opclass.oid |
partcollation |
oidvectorNOT NULL |
For each column in the partition key, this contains the OID of the collation to use for partitioning, or zero if the column is not of a collatable data type.References:pg_collation.oid |
partexprs |
pg_node_tree |
Expression trees (in nodeToString() representation) for partition key columns that are not simple column references. This is a list with one element for each zero entry in partattrs. Null if all partition key columns are simple references. |
Columns marked "implicit" are not included in SELECT *; some early statistics views are completed from same-version source, and the extra provenance is shown in the column description.
Common system columns 6
System attributes PostgreSQL provides, normally not expanded by SELECT *. Kept separately so they are not mixed in with ordinary columns.
| Columns | Type | attnum |
|---|---|---|
tableoid | oid | -6 |
cmax | cid | -5 |
xmax | xid | -4 |
cmin | cid | -3 |
xmin | xid | -2 |
ctid | tid | -1 |
Column evolution matrix
Hover a cell for the column type9.0 is the coverage baseline; a column already present in the baseline is not marked as added. The matrix aligns columns by name, so a rename appears as the old column removed and a new column added.
Evolution timeline
Changes between adjacent majorsPostgreSQL 11 ← 10
PostgreSQL 10 ← 9.6Catalog added
Compare any two versions
Pick two versions to see added, removed, and retyped columns. The interactive comparison needs JavaScript; the evolution timeline reads fine without it.