RE: Simple SQL Query

From: Goulet, Richard <Richard.Goulet_at_parexel.com>
Date: Thu, 7 Jan 2010 12:21:23 -0500
Message-ID: <6B0D50B70F12BD41B5A67F14F5AA887F03512E7A_at_us-bos-mx022.na.pxl.int>



What database version???  

Dick Goulet
Senior Oracle DBA/NA Team Lead
PAREXEL International  


From: oracle-l-bounce_at_freelists.org
[mailto:oracle-l-bounce_at_freelists.org] On Behalf Of Pani Babu Sent: Thursday, January 07, 2010 12:04 PM To: oracle-l_at_freelists.org
Subject: Simple SQL Query

I have a simple SQL query which lists all the records that are not in a second table.

select first.id from first
where first.id not in (select id from second);

As the second table is very huge, it takes a very long to process the query.
Is there a way to rewrite the query to run it quicker?

--
http://www.freelists.org/webpage/oracle-l
Received on Thu Jan 07 2010 - 11:21:23 CST

Original text of this message