RE: PL SQL cursor help

  • From: Stephen.Lee@xxxxxxxx
  • To: oracle-l@xxxxxxxxxxxxx
  • Date: Mon, 22 Mar 2004 08:51:16 -0600

If you must have periodic commits, the COPY command works very well.

set copycommit 5000 (5000 is as high as you can go, iirc)
set long 65000 (if needed)
set arraysize 100 (or whatever)

copy from joebob.sma@box1 insert billybob.local_table using SELECT * FROM
sma a WHERE exists (select 1 from mr15421 b where a.sched_id = b.sched_id
and a.proc_cd = b.proc_cd and a.proc_catg_cd = b.proc_catg_cd and
a.compnnt_typ_cd = b.compnnt_typ_cd and a.eff_dt = b.eff_dt);

I don't know this for a fact, but I get that feeling that the copy command
uses the sql loader mechanism underneath the covers.  Whatever it uses, it's
moves data at a good rate of speed.

----------------------------------------------------------------
Please see the official ORACLE-L FAQ: http://www.orafaq.com
----------------------------------------------------------------
To unsubscribe send email to:  oracle-l-request@xxxxxxxxxxxxx
put 'unsubscribe' in the subject line.
--
Archives are at //www.freelists.org/archives/oracle-l/
FAQ is at //www.freelists.org/help/fom-serve/cache/1.html
-----------------------------------------------------------------

Other related posts: