Re: Question regarding 'not in' and subselects - Mailing list pgsql-bugs

From Vic Ricker
Subject Re: Question regarding 'not in' and subselects
Date
Msg-id 1085600526.3926.7.camel@tablet.ricker.us
Whole thread Raw
In response to Re: Question regarding 'not in' and subselects  (Bruno Wolff III <bruno@wolff.to>)
List pgsql-bugs
On Wed, 2004-05-26 at 14:38, Bruno Wolff III wrote:
> On Wed, May 26, 2004 at 13:57:37 -0400,
>   Vic Ricker <vicricker@charter.net> wrote:
> > Am I doing something wrong or is this a bug?
>
> Are there any nulls in iasusers.user_name?

There was a null in iasusers.  I removed it and that fixed the problem.
I'm not sure that I understand why.  It doesn't seem very intuitive...
:-)

Tom Innes's suggestion of:

select u.user_name from users u where u.user_name not in (select
user_name from iasusers ia where ia.user_name = u.user_name);

also worked.

Thanks guys!

--
Vic Ricker
http://www.ricker.us/

pgsql-bugs by date:

Previous
From: Bruno Wolff III
Date:
Subject: Re: Question regarding 'not in' and subselects
Next
From: "Sergey N. Yatskevich"
Date:
Subject: Bug in ECPG preprocessor