Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtp (Exim 4.84_2) (envelope-from ) id 1dK7Rw-0002oP-Hs for pgsql-hackers@arkaria.postgresql.org; Sun, 11 Jun 2017 18:18:56 +0000 Received: from localhost ([127.0.0.1] helo=postgresql.org) by malur.postgresql.org with smtp (Exim 4.84_2) (envelope-from ) id 1dK7Rv-0008Kr-N5 for pgsql-hackers@arkaria.postgresql.org; Sun, 11 Jun 2017 18:18:55 +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 1dK7Rt-0008Kf-SR for pgsql-hackers@postgresql.org; Sun, 11 Jun 2017 18:18:54 +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 1dK7Rm-000576-Rk for pgsql-hackers@postgresql.org; Sun, 11 Jun 2017 18:18:52 +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 v5BIIfH3028632; Sun, 11 Jun 2017 14:18:42 -0400 From: Tom Lane To: Alvaro Herrera cc: Andres Freund , Mark Dilger , Regina Obe , PostgreSQL-development Subject: Re: PostgreSQL 10 changes in exclusion constraints - did something change? CASE WHEN behavior oddity In-reply-to: <20170610180419.2gref4t7oipjcri5@alvherre.pgsql> References: <20170610180419.2gref4t7oipjcri5@alvherre.pgsql> Comments: In-reply-to Alvaro Herrera message dated "Sat, 10 Jun 2017 15:04:19 -0300" MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-ID: <28630.1497205121.1@sss.pgh.pa.us> Date: Sun, 11 Jun 2017 14:18:41 -0400 Message-ID: <28631.1497205121@sss.pgh.pa.us> 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 Alvaro Herrera writes: > Interesting stuff. Here's a small recommendation for a couple of those > new messages. Hm. I don't object to folding those two messages into one, but now that I look at it, the text needs some more work anyway, perhaps. What we're actually checking is not so much whether the IS DISTINCT FROM construct returns a set as whether the underlying equality operator does. If we want to be pedantic about it, we'd end up writing something like "equality operator used by %s must not return a set" But perhaps it's okay to fuzz the distinction and just write "%s must not return a set" You could justify that on the reasoning that if we were to allow this then an underlying "=" that returned a set would presumably cause IS DISTINCT FROM or NULLIF to also return a set. I'm kind of thinking that the second wording is preferable, but there's room to argue that the first is more precise. Opinions? regards, tom lane -- Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-hackers