There is no error reported when a field in the subselect is not part of the subselect table but exists in the main table.
Try This: nsd=# create table a ( f1 int, f2 text); CREATE nsd=# create table b ( f3 int, f4 text); CREATE nsd=# select * from a where f1 in ( select f1 from b); f1 | f2 ----+---- (0 rows) nsd=# select version(); version ------------------------------------------------------------- PostgreSQL 7.2.1 on i686-pc-linux-gnu, compiled by GCC 2.96 (1 row) ---------------------------(end of broadcast)--------------------------- TIP 3: if posting/reading through Usenet, please send an appropriate subscribe-nomail command to [EMAIL PROTECTED] so that your message can get through to the mailing list cleanly