Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
![]() |
![]() |
Home -> Community -> Usenet -> c.d.o.misc -> Re: SQL - long list in the where clause. Any ideas?
I would suggest creating a table (or if it is available from other tables,
a view) to hold these part numbers. Also, IN or NOT IN is usually slower
than EXISTS / NOT EXISTS. I'd write it like
select * from your_table T where exists (select 1 from bad_parts where
part_number = T.part_number)
Received on Sat Feb 01 2003 - 06:47:20 CST
![]() |
![]() |