Re: EXISTS vs IN vs OUTER JOINS - Mailing list pgsql-performance

From Josh Berkus
Subject Re: EXISTS vs IN vs OUTER JOINS
Date
Msg-id web-2292427@davinci.ethosmedia.com
Whole thread Raw
In response to Re: EXISTS vs IN vs OUTER JOINS  (jasiek@klaster.net)
Responses Re: EXISTS vs IN vs OUTER JOINS
Re: EXISTS vs IN vs OUTER JOINS
List pgsql-performance
Tomasz,

> I read your mail once again, but I still don't understand what are
> you
> talking about.
> I'll write example - maybe it will help us to understand each other.

Hmmm ... you're right.  Sorry for being dense.  It shouldn't work, but
it does.

Tom, Bruce:

If I run the query:

SELECT t1.*
FROM table1 t1
  LEFT JOIN table2 t2 ON t1.xid = t2.xid
WHERE t2.label IS NULL

I will get rows in t1 for which there is no row in t2.  This does not
seem SQL-spec to me; shouldn't I get only rows from t1 where a row
exists in t2 and t2.label IS NULL?

-Josh

pgsql-performance by date:

Previous
From: Bruce Momjian
Date:
Subject: Re: EXISTS vs IN vs OUTER JOINS
Next
From: Tom Lane
Date:
Subject: Re: EXISTS vs IN vs OUTER JOINS