Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
![]() |
![]() |
Home -> Community -> Usenet -> c.d.o.misc -> Re: query taking too much time to execute
Kuldeep wrote:
> delete from ASSORTMENT
> where ASSORTM not in ( select min(ASSORTM)
> from ASSORTMENT
> group by ASSORTM2 )
>
> This query is teking too musc time to execute
>
> In ASSORTMENT there are 1,50,000 records
>
> somebdy has solution over it?
First rule of performance improvement: Know thy data.
However since you post no sample data, no table definitions, and no explain plan, giving advice on this one is tough. THe solution is going to depend on your data. I will suggest you consider other ways of writing the query than using NOT IN. (Options include for example a correlated NOT EXISTS clause.)
HTH,
ed
Received on Sun Apr 23 2006 - 17:31:27 CDT
![]() |
![]() |