pg_subscription

A system catalogue table containing all existing logical replication subscriptions

pg_subscription is a system catalogue table containing all existing logical replication subscriptions.

pg_subscription was added in PostgreSQL 10 (commit 665d1fad).

This table is shared across all databases in a cluster.

Definition by PostgreSQL version

pg_subscription (PostgreSQL 13)

             Table "pg_catalog.pg_subscription"
     Column      |  Type   | Collation | Nullable | Default
-----------------+---------+-----------+----------+---------
 oid             | oid     |           | not null |
 subdbid         | oid     |           | not null |
 subname         | name    |           | not null |
 subowner        | oid     |           | not null |
 subenabled      | boolean |           | not null |
 subconninfo     | text    | C         | not null |
 subslotname     | name    |           | not null |
 subsynccommit   | text    | C         | not null |
 subpublications | text[]  | C         | not null |
Indexes:
    "pg_subscription_oid_index" UNIQUE, btree (oid), tablespace "pg_global"
    "pg_subscription_subname_index" UNIQUE, btree (subdbid, subname), tablespace "pg_global"
Tablespace: "pg_global"
    

Documentation: pg_subscription

pg_subscription (PostgreSQL 12)

             Table "pg_catalog.pg_subscription"
     Column      |  Type   | Collation | Nullable | Default
-----------------+---------+-----------+----------+---------
 oid             | oid     |           | not null |
 subdbid         | oid     |           | not null |
 subname         | name    |           | not null |
 subowner        | oid     |           | not null |
 subenabled      | boolean |           | not null |
 subconninfo     | text    | C         | not null |
 subslotname     | name    |           | not null |
 subsynccommit   | text    | C         | not null |
 subpublications | text[]  | C         | not null |
Indexes:
    "pg_subscription_oid_index" UNIQUE, btree (oid), tablespace "pg_global"
    "pg_subscription_subname_index" UNIQUE, btree (subdbid, subname), tablespace "pg_global"
Tablespace: "pg_global"
    

Documentation: pg_subscription

pg_subscription (PostgreSQL 11)

             Table "pg_catalog.pg_subscription"
     Column      |  Type   | Collation | Nullable | Default
-----------------+---------+-----------+----------+---------
 subdbid         | oid     |           | not null |
 subname         | name    |           | not null |
 subowner        | oid     |           | not null |
 subenabled      | boolean |           | not null |
 subconninfo     | text    |           | not null |
 subslotname     | name    |           | not null |
 subsynccommit   | text    |           | not null |
 subpublications | text[]  |           | not null |
Indexes:
    "pg_subscription_oid_index" UNIQUE, btree (oid), tablespace "pg_global"
    "pg_subscription_subname_index" UNIQUE, btree (subdbid, subname), tablespace "pg_global"
Tablespace: "pg_global"
    

Documentation: pg_subscription

pg_subscription (PostgreSQL 10)

             Table "pg_catalog.pg_subscription"
     Column      |  Type   | Collation | Nullable | Default
-----------------+---------+-----------+----------+---------
 subdbid         | oid     |           | not null |
 subname         | name    |           | not null |
 subowner        | oid     |           | not null |
 subenabled      | boolean |           | not null |
 subconninfo     | text    |           | not null |
 subslotname     | name    |           | not null |
 subsynccommit   | text    |           | not null |
 subpublications | text[]  |           | not null |
Indexes:
    "pg_subscription_oid_index" UNIQUE, btree (oid), tablespace "pg_global"
    "pg_subscription_subname_index" UNIQUE, btree (subdbid, subname), tablespace "pg_global"
Tablespace: "pg_global"
    

Documentation: pg_subscription

Change history

This table has not been modified since it was added in PostgreSQL 10.

Categories

Cluster-wide table, Replication, System catalogue

See also

pg_subscription_rel