Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtp (Exim 4.84_2) (envelope-from ) id 1dwDfT-0004do-7F for pgsql-bugs@arkaria.postgresql.org; Sun, 24 Sep 2017 20:38:23 +0000 Received: from localhost ([127.0.0.1] helo=postgresql.org) by malur.postgresql.org with smtp (Exim 4.84_2) (envelope-from ) id 1dwDfS-00078q-NK for pgsql-bugs@arkaria.postgresql.org; Sun, 24 Sep 2017 20:38:22 +0000 Received: from makus.postgresql.org ([2001:4800:1501:1::229]) by malur.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.84_2) (envelope-from ) id 1dwDej-0003MF-Ad; Sun, 24 Sep 2017 20:37:37 +0000 Received: from sss.pgh.pa.us ([66.207.139.130]) by makus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.84_2) (envelope-from ) id 1dwDeg-0003XJ-K1; Sun, 24 Sep 2017 20:37:36 +0000 Received: from sss1.sss.pgh.pa.us (localhost [127.0.0.1]) by sss.pgh.pa.us (8.14.4/8.14.4) with ESMTP id v8OKbU0Q018128; Sun, 24 Sep 2017 16:37:30 -0400 From: Tom Lane To: Andrew Dunstan cc: balazs@obiserver.hu, pgsql-bugs@postgresql.org, pgsql-hackers@postgresql.org Subject: Re: BUG #14825: enum type: unsafe use? In-reply-to: <9479302a-09b8-4264-f9c4-514b65f18547@2ndQuadrant.com> References: <20170922185904.1448.16585@wrigleys.postgresql.org> <15165.1506116768@sss.pgh.pa.us> <3cece400-af56-7145-2e65-f044de1b0b68@2ndQuadrant.com> <28968.1506136792@sss.pgh.pa.us> <24380.1506179805@sss.pgh.pa.us> <16272.1506189656@sss.pgh.pa.us> <928f5974-151f-0273-0221-fac213e7624f@2ndQuadrant.com> <19137.1506196325@sss.pgh.pa.us> <4942e2c0-3302-f496-d4c1-a967f77d0143@2ndQuadrant.com> <25662.1506204381@sss.pgh.pa.us> <9479302a-09b8-4264-f9c4-514b65f18547@2ndQuadrant.com> Comments: In-reply-to Andrew Dunstan message dated "Sun, 24 Sep 2017 16:19:37 -0400" MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-ID: <18126.1506285450.1@sss.pgh.pa.us> Date: Sun, 24 Sep 2017 16:37:30 -0400 Message-ID: <18127.1506285450@sss.pgh.pa.us> List-Archive: List-Help: List-ID: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: X-Mailing-List: pgsql-bugs Precedence: bulk Sender: pgsql-bugs-owner@postgresql.org Andrew Dunstan writes: > OK, here's the finished patch. It has a pretty small footprint all > things considered, and I think it guarantees that nothing that could be > done in this area in 9.6 will be forbidden. That's probably enough to > get us to 10 without having to revert the whole thing, ISTM, and we can > leave any further refinement to the next release. I think this could do with some more work on the comments and test cases, but it's basically sound. What we still need to debate is whether to remove the heuristic type-is-from-same-transaction test, making the user-visible behavior simply "you must commit an ALTER TYPE ADD VALUE before you can use the new value". I'm kind of inclined to do so; the fuzzy (and inadequately documented) behavior we'll have if we keep it doesn't seem very nice to me. regards, tom lane -- Sent via pgsql-bugs mailing list (pgsql-bugs@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-bugs