Re: Making serial survive pg_dump

From: Josh Berkus <josh(at)agliodbs(dot)com>
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, "Rod Taylor" <rbt(at)zort(dot)ca>
Cc: "Hackers List" <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: Making serial survive pg_dump
Date: 2002-06-13 23:55:52
Message-ID: 200206131655.52871.josh@agliodbs.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers


Folks,

> No. IMHO, if we change the naming convention for serial sequences (which
> seems unlikely, except that it might be indirectly affected by changing
> NAMEDATALEN), then we'd *want* the new naming convention to take effect,
> not to have pg_dump scripts force an old naming convention to be
> preserved.
>
> I realize there's a potential for failing to restore the setval()
> information if the name actually does change, but I'm willing to live
> with that.

IMNHO, if this is such a concern for the developer, then what about using
explicitly named sequences? I almost never use the SERIAL data type, because
I feel that I need naming control as well as explicit permissions. SERIAL is
a convenience for those who don't want to be bothered ... serious developers
hould use DEFAULT NEXTVAL('sequence_name').

--
-Josh Berkus

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message David Ford 2002-06-14 00:10:47 ATTN: Tom Lane
Previous Message David Ford 2002-06-13 23:46:16 Re: PostGres Doubt