第1个回答 2012-08-11
declare
i number:=0;
begin
for rec in (select * from cux_xxxx) loop--select * from cux_xxxx为你的5500条数据
--你的操作
insert ...
update...
--你的操作.end
i :=i+1;
--每1000条保存一次,到最后剩下500条也保存一次
if i mod 1000 in (0,500) then
commit;
end if;
end loop;
end;