Re: Re: [COMMITTERS] pgsql: Update: < * Allow adding enumerated values to an existing - Mailing list pgsql-hackers

From Brendan Jurd
Subject Re: Re: [COMMITTERS] pgsql: Update: < * Allow adding enumerated values to an existing
Date
Msg-id 37ed240d0804251140sefb215p42fdfc34588ca91a@mail.gmail.com
Whole thread Raw
In response to Re: [COMMITTERS] pgsql: Update: < * Allow adding enumerated values to an existing  (Alvaro Herrera <alvherre@commandprompt.com>)
Responses Re: Re: [COMMITTERS] pgsql: Update: < * Allow adding enumerated values to an existing  (Tom Lane <tgl@sss.pgh.pa.us>)
Re: Re: [COMMITTERS] pgsql: Update: < * Allow adding enumerated values to an existing  ("Tom Dunstan" <pgsql@tomd.cc>)
List pgsql-hackers
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

On Sat, Apr 26, 2008 at 4:27 AM, Alvaro Herrera  wrote:
> Andrew Dunstan wrote:
>  >
>  > Bruce Momjian wrote:
>  >> Log Message:
>  >> -----------
>  >> Update:
>  >>
>  >>   >>
>  >>> * Allow adding/removing enumerated values to an existing enumerated data
>  >
>  > Where did this come from? Adding values anywhere except on the end of
>  > the enumeration list will be fraught with danger, as will removing them.
>  > In essence, either operation would entail rewriting every table that
>  > used the type. Anything else carries a major risk of corruption. That
>  > seems like a pretty bad idea.
>
>  We already support rewriting tables ... (albeit only one at a time, I
>  admit.  Doing it for more than one can cause deadlocks).
>
>  Still, if the user wants to pay the cost, why should we prohibit it?
>

I agree with Alvaro's sentiment here, but it  does seem likely that
adding an value to the end of an enum list is much lower-hanging fruit
than add/remove.

Has anyone had a close look at how hard it would be allow just the
"add to the end" capability?

Cheers,
BJ
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.7 (GNU/Linux)
Comment: http://getfiregpg.org

iD8DBQFIEiWO5YBsbHkuyV0RAo5pAKDMQ7aAbJJyIe74c+PacXVXg5chXACdEnv3
sFiNsSf193/C9HpW5UVhYWs=
=jOzI
-----END PGP SIGNATURE-----


pgsql-hackers by date:

Previous
From: Alvaro Herrera
Date:
Subject: Re: [COMMITTERS] pgsql: Update: < * Allow adding enumerated values to an existing
Next
From: Gregory Stark
Date:
Subject: Re: Proposed patch - psql wraps at window width