Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.server -> Re: optimal sql

Re: optimal sql

From: Martin Doherty <martin.doherty_at_oorraaccllee.com>
Date: Mon, 09 Dec 2002 03:13:48 -0800
Message-ID: <B__I9.4$e14.36@news.oracle.com>


NOT IN becomes very inefficient for many values.

try NOT EXISTS instead.

Martin Doherty

Christoph Seidel wrote:

>how can i find all records by pk in table 1 which are not in table 2
>
>is this efficient:?
>
>select * from t1 where pk not in (select pk from t2)
>
>
>
>
Received on Mon Dec 09 2002 - 05:13:48 CST

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US