SQL query
From: <Mayen.Shah_at_lazard.com>
Date: Mon, 12 Apr 2010 14:57:00 -0400
Message-ID: <OF835713E1.EC5B2303-ON85257703.006728B3-85257703.0068187A_at_lazard.com>
Hi Listers,
Date: Mon, 12 Apr 2010 14:57:00 -0400
Message-ID: <OF835713E1.EC5B2303-ON85257703.006728B3-85257703.0068187A_at_lazard.com>
Hi Listers,
One of my colleagues has challenged me with SQL question. I can not figure out how to do this.
SQL> select * from test1;
COL1 COL2
---------- ----------
11 21 12 22 13 23 14 25
4 rows selected.
SQL> select * from test2;
COL3 COL4
---------- ----------
41 51 42 52 43 53 13 23 14 25
5 rows selected.
Here is simple query.
SQL> select col1 from test1 where col1 not in (select col3 from test2);
COL1
11 12
2 rows selected.
I have to rewrite this query where I can't use NOT or MINUS.
Can anyone help me?
Thanks
Mayen
--
http://www.freelists.org/webpage/oracle-l
Received on Mon Apr 12 2010 - 13:57:00 CDT