select open change scope Open full search

PG.CENTER connects PostgreSQL documentation, reference, and ecosystem knowledge. Maintained by Pigsty.

SYSTEM CATALOGS / SYSTEM VIEWS

The view pg_sequences provides access to useful information about each sequence in the database.

Kind
System views
Columns in this snapshot
11
Definition source
English manual

Columns 11

ColumnTypeDescription / reference
schemanamenameName of schema containing sequence
pg_namespace.nspname
sequencenamenameName of sequence
pg_class.relname
sequenceownernameName of sequence's owner
pg_authid.rolname
data_typeregtypeData type of the sequence
pg_type.oid
start_valueint8Start value of the sequence
min_valueint8Minimum value of the sequence
max_valueint8Maximum value of the sequence
increment_byint8Increment value of the sequence
cycleboolWhether the sequence cycles
cache_sizeint8Cache size of the sequence
last_valueint8The last sequence value written to disk. If caching is used, this value can be greater than the last value handed out from the sequence.
Column history across versions
Version history 2
  1. PG 14 → 15changed
  2. PG 9.6 → 10added

Definition snapshot: english-manuals:da0073a46a1ffd8fbb090318b51… · English manual source