delete A a where not exists (select 1 from B d
where a.id_no=d.id_no and d.use_number =1)怎么让它执行的效率提高阿????
A表和B表都很大,大概都4千万的样子,A,B的ID_NO 都有索引,上面执行花了四个小时还是没跑出来...请教了........
where a.id_no=d.id_no and d.use_number =1)怎么让它执行的效率提高阿????
A表和B表都很大,大概都4千万的样子,A,B的ID_NO 都有索引,上面执行花了四个小时还是没跑出来...请教了........
从A表中删除记录,条件是id_no在B表中不存在并且B表的number=1的记录not exists表示在B表中不存在的id_no
10g
alter system flush buffer_cache;
9i
alter session set events = 'immediate trace name flush_cache';To flush shared pool (parsed SQls/PL/SQLs:alter system flush shared_pool;