pg.ddx.io  pgsql-sql@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Yon Den Baguse Ngarso <yon@dugem.com>
To: pgsql-sql@postgresql.org
Subject: SELECT ... WHERE ... NOT IN (SELECT ...);
Date: Thu, 22 Aug 2002 20:39:52 -0700 (PDT)
Message-ID: <20020823033952.64A443955@sitemail.everyone.net> (raw)

opennms=# SELECT eventid FROM tbl1;
 eventid
---------
  119064
  119064
   60116
   16082
   16082
   16303
   16082
   92628
   92628
   60083
(10 rows)


opennms=# SELECT eventid FROM tbl2;
 eventid
---------
  123989
  123989
  123989
   16134
   16134
   16368
   16134
   92685
   92685
   60115
(10 rows)


opennms=# SELECT eventid FROM tbl1 WHERE eventid NOT IN (SELECT eventid FROM tbl2);

 eventid
---------
(0 rows)

I'm confused, the result should not 0 rows, right?

Pls Help. Am I missing something?

TIA.

_____________________________________________________________
Get yourname@dugem.com at http://www.dugem.com

_____________________________________________________________
Promote your group and strengthen ties to your members with email@yourgroup.org by Everyone.net  http://www.everyone.net/?btn=tag



view thread (9+ messages)  latest in thread

Message-ID: <20020823033952.64A443955@sitemail.everyone.net>
Permalink:  ../20020823033952.64A443955@sitemail.everyone.net/
Also on:    postgresql.org/message-id/20020823033952.64A443955@sitemail.everyone.net

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients using the --to and --cc options:
  reply via email

  To: pgsql-sql@postgresql.org
  Cc: yon@dugem.com
  Subject: Re: SELECT ... WHERE ... NOT IN (SELECT ...);
  In-Reply-To: <20020823033952.64A443955@sitemail.everyone.net>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox