Re: Unused(?) field Form_pg_sequence.sequence_name, not updated by seq rename - Mailing list pgsql-hackers

From Tom Lane
Subject Re: Unused(?) field Form_pg_sequence.sequence_name, not updated by seq rename
Date
Msg-id 14203.1450155926@sss.pgh.pa.us
Whole thread Raw
In response to Unused(?) field Form_pg_sequence.sequence_name, not updated by seq rename  (Craig Ringer <craig@2ndquadrant.com>)
Responses Re: Unused(?) field Form_pg_sequence.sequence_name, not updated by seq rename  (Michael Paquier <michael.paquier@gmail.com>)
List pgsql-hackers
Craig Ringer <craig@2ndquadrant.com> writes:
> Does anyone know why Form_pg_sequence has a field sequence_name that
> duplicates the sequence's name from pg_class ?

It's historical, for sure.  We won't be removing it in the foreseeable
future because of on-disk-compatibility issues.  But you might want to
read the pghackers archives, five or ten years back, where we speculated
about redoing sequences to combine them all into one system catalog
(ie, store one row per sequence not one relation per).  Aside from
application compatibility issues, the stumbling block seemed to be how to
separate transactional from nontransactional updates.  That particular
problem is also why ALTER SEQUENCE RENAME can't update the sequence's copy
of the relation name: the wrong things happen if you roll back.
        regards, tom lane



pgsql-hackers by date:

Previous
From: Craig Ringer
Date:
Subject: Unused(?) field Form_pg_sequence.sequence_name, not updated by seq rename
Next
From: amul sul
Date:
Subject: small query, about skipping dump in dumpAttrDef