Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtp (Exim 4.84_2) (envelope-from ) id 1ajXLJ-0003l1-8l for pgsql-hackers@arkaria.postgresql.org; Fri, 25 Mar 2016 19:24:21 +0000 Received: from localhost ([127.0.0.1] helo=postgresql.org) by malur.postgresql.org with smtp (Exim 4.84_2) (envelope-from ) id 1ajXLI-0005V8-Qf for pgsql-hackers@arkaria.postgresql.org; Fri, 25 Mar 2016 19:24:20 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.84_2) (envelope-from ) id 1ajXJw-0002dm-Cq for pgsql-hackers@postgresql.org; Fri, 25 Mar 2016 19:22:56 +0000 Received: from mbx.knossos.net.nz ([202.160.48.10]) by magus.postgresql.org with esmtp (Exim 4.84_2) (envelope-from ) id 1ajXJs-0000sz-IC for pgsql-hackers@postgresql.org; Fri, 25 Mar 2016 19:22:55 +0000 Received: from [10.1.1.3] (dynamic-cpe-pool.orcon.net.nz [121.98.103.53] (may be forged)) (authenticated bits=0) by mbx.knossos.net.nz (8.14.4/8.14.4) with ESMTP id u2PJMYi6027618 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES128-SHA bits=128 verify=NOT); Sat, 26 Mar 2016 08:22:35 +1300 Subject: Re: Alter or rename enum value To: Jim Nasby , Tom Lane References: <56E049CC.8010201@dunslane.net> <25605.1457539654@sss.pgh.pa.us> <56E05635.70908@dunslane.net> <28167.1457543612@sss.pgh.pa.us> <56F49CF8.8050007@BlueTreble.com> <27476.1458876456@sss.pgh.pa.us> <56F58EAC.4040802@BlueTreble.com> Cc: Matthias Kurz , pgsql-hackers@postgresql.org From: Gavin Flower Organization: ArchiDevSys Message-ID: <56F58FF9.101@archidevsys.co.nz> Date: Sat, 26 Mar 2016 08:22:33 +1300 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:38.0) Gecko/20100101 Thunderbird/38.6.0 MIME-Version: 1.0 In-Reply-To: <56F58EAC.4040802@BlueTreble.com> Content-Type: text/plain; charset=windows-1252; format=flowed Content-Transfer-Encoding: 7bit X-Pg-Spam-Score: -1.9 (-) List-Archive: List-Help: List-ID: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: X-Mailing-List: pgsql-hackers Precedence: bulk Sender: pgsql-hackers-owner@postgresql.org On 26/03/16 08:17, Jim Nasby wrote: > On 3/24/16 10:27 PM, Tom Lane wrote: >> It's conceivable that we could do something like adding an "isdead" >> column to pg_enum and making enum_in reject new values that're marked >> isdead. But I can't see that we'd ever be able to support true >> removal of an enum value at reasonable cost. And I'm not really sure >> where the use-case argument is for working hard on it. > > I wonder if we could handle this by allowing foreign keys on enum > columns back to pg_enum. Presumably that means we'd have to treat > pg_enum as a regular table and not a catalog table. Due to locking > concerns I don't think we'd want to put the FKs in place by default > either. > > I've certainly heard people avoiding ENUMs because of their > limitations, so it'd be nice if there was a way to lift them. Well, I use Enums extensively in Java. However, I totally avoid using ENUMs in pg, due to their inflexibility! Cheers, Gavin -- Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-hackers