Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Mailing Lists -> Oracle-L -> RE: PL SQL cursor help

RE: PL SQL cursor help

From: <Stephen.Lee_at_DTAG.Com>
Date: Tue, 23 Mar 2004 21:17:58 -0600
Message-ID: <D6339830FC73944E889CC3CEADDB205B079092B4@bu-dtagpo1.tracs.com>

I use it all the time. It's great. I love it. It's one of the most useful additions to Oracle. I have a rather large ksh script I use to load test and development from production that is based on the copy command. The script reads a config file that identifies the tables to load; disables constraints, indexes, and any dependant foreign keys; loads the tables; rebuilds the indexes and enables the constraints. I can define a query for each table if the table is to get only a subset of the production data. The copy command is your friend (as is vi!).

I suppose you got the correction, in a follow-up post, to the syntax error that was in my first post.

> -----Original Message-----
> Thanks, That sounds like an easy way to accomplish what I was trying
> to do. I'll have to play around with that.
>
> Stephen
>
> >>> Stephen.Lee_at_DTAG.Com 03/22/04 07:51AM >>>
>
> 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_at_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);
>



Please see the official ORACLE-L FAQ: http://www.orafaq.com

To unsubscribe send email to: oracle-l-request_at_freelists.org put 'unsubscribe' in the subject line.
--
Archives are at http://www.freelists.org/archives/oracle-l/
FAQ is at http://www.freelists.org/help/fom-serve/cache/1.html
-----------------------------------------------------------------
Received on Tue Mar 23 2004 - 21:15:10 CST

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US