Summary
The catalog pg_sequence contains information about sequences. Some of the information about sequences, such as the name and the schema, is in pg_class
(Description quoted from the official PostgreSQL documentation.)
Columns
The pg_sequence system catalog exposes the following columns (names, types and descriptions are taken verbatim from the PostgreSQL documentation):
seqrelidoidreferencespg_class.oid
The OID of the pg_class entry for this sequenceseqtypidoidreferencespg_type.oid
Data type of the sequenceseqstartint8
Start value of the sequenceseqincrementint8
Increment value of the sequenceseqmaxint8
Maximum value of the sequenceseqminint8
Minimum value of the sequenceseqcacheint8
Cache size of the sequenceseqcyclebool
Whether the sequence cycles
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_sequence.