Re: Oddity with NOT IN - Mailing list pgsql-hackers

From Jim Nasby
Subject Re: Oddity with NOT IN
Date
Msg-id 647bf2a5-f93a-21ee-d75b-541c08588c20@BlueTreble.com
Whole thread Raw
In response to Re: Oddity with NOT IN  (Pavel Stehule <pavel.stehule@gmail.com>)
Responses Re: Oddity with NOT IN  (Pavel Stehule <pavel.stehule@gmail.com>)
List pgsql-hackers
On 8/6/16 12:03 PM, Pavel Stehule wrote:
>     It would be very useful if we had some way to warn users about stuff
>     like this. Emitting a NOTICE comes to mind.
>
>
> This can be valid query

Right, but in my experience it's an extremely uncommon pattern and much 
more likely to be a mistake (that ends up being very time consuming to 
debug). That's why I think something like a NOTICE or even a WARNING 
would be useful. The only thing I don't like about that idea is if you 
ever did actually want this behavior you'd have to do something to 
squash the ereport. Though, that's a problem we already have in some 
places, so perhaps not worth worrying about.
-- 
Jim Nasby, Data Architect, Blue Treble Consulting, Austin TX
Experts in Analytics, Data Architecture and PostgreSQL
Data in Trouble? Get it in Treble! http://BlueTreble.com
855-TREBLE2 (855-873-2532)   mobile: 512-569-9461



pgsql-hackers by date:

Previous
From: Andrew Gierth
Date:
Subject: Re: Oddity with NOT IN
Next
From: Pavel Stehule
Date:
Subject: Re: Oddity with NOT IN