Re: Adding a pg_get_owned_sequence function?

From: Peter Eisentraut <peter(at)eisentraut(dot)org>
To: Dagfinn Ilmari Mannsåker <ilmari(at)ilmari(dot)org>, pgsql-hackers(at)postgresql(dot)org
Subject: Re: Adding a pg_get_owned_sequence function?
Date: 2023-09-12 07:33:54
Views: Raw Message | Whole Thread | Download mbox | Resend email
Lists: pgsql-hackers

On 09.06.23 21:19, Dagfinn Ilmari Mannsåker wrote:
> I've always been annoyed by the fact that pg_get_serial_sequence takes
> the table and returns the sequence as strings rather than regclass. And
> since identity columns were added, the name is misleading as well (which
> is even acknowledged in the docs, together with a suggestion for a
> better name).

If you are striving for less misleading terminology, note that the
concept of an "owned sequence" does not exist for users of identity
sequences, and ALTER SEQUENCE / OWNED BY cannot be used for such sequences.

Would it work to just overload pg_get_serial_sequence with regclass
argument types?

In response to


Browse pgsql-hackers by date

  From Date Subject
Next Message Peter Eisentraut 2023-09-12 07:46:31 Re: proposal: psql: show current user in prompt
Previous Message 쿼리트릭스 2023-09-12 07:27:18 Re: [ psql - review request ] review request for \d+ tablename, \d+ indexname indenting