Re: BUG #2178: NOT IN command don't work - Mailing list pgsql-bugs

From Michael Fuhr
Subject Re: BUG #2178: NOT IN command don't work
Date
Msg-id 20060119214042.GA15276@winnie.fuhr.org
Whole thread Raw
In response to BUG #2178: NOT IN command don't work  ("Daniel Afonso Heisler" <daniel@solis.coop.br>)
List pgsql-bugs
On Tue, Jan 17, 2006 at 10:00:28PM +0000, Daniel Afonso Heisler wrote:
> When i run the following query, postgreSQL return TRUE.
>  # SELECT true WHERE 1 NOT IN (2,3);
>
> But, when i run the next query, it don't return TRUE
>  # SELECT true WHERE 1 NOT IN (2,NULL,3);

The expression "1 NOT IN (2,NULL,3)" evaluates to NULL because NULL
means "unknown."  This comes up occasionally; see the archives for
past discussion.

http://archives.postgresql.org/pgsql-sql/2005-12/msg00219.php
http://archives.postgresql.org/pgsql-sql/2005-10/msg00227.php

--
Michael Fuhr

pgsql-bugs by date:

Previous
From: Tom Lane
Date:
Subject: Re: BUG #2180: log_statement=mod does not work
Next
From: Bruce Momjian
Date:
Subject: Re: BUG #2177: (minor:) pgsql: Trailing semicolon on \d treated