RE: How to copy Procedure into a another DB.

RE: How to copy Procedure into a another DB.

 

  

Spooling works well. However, you can also view the source from OEM and
copy and paste the text into a file. With a few minor tweaks like adding
create or replace and adding a "/" you should be good to go. For a single
proc, OEM seems to be a bit faster. To use the spooled output, you will
need to shut off headers, trim white space, etc., and edit the output a bit
as with OEM.

For a large number of objects, spooling is better. For a small number, OEM
is a but faster.

Good Luck!
Chris

----------------------------------------------------
Chris Weiss, Blueoak Database Engineering, LLC
http://www.blueoakdb.com
PH: 517-381-9305
CELL: 517-974-5634
eFAX: 801-340-0740


-----Original Message-----
From: Titus Olowok
[mailto:oracledba-ezmlmshield-x65531204.[Email address protected]
Sent: Tuesday, August 31, 2004 3:46 PM
To: LazyDBA Discussion
Subject: Re: How to copy Procedure into a another DB.


set pages 0 lines 150
spool <spool_file_name>.sql
select text from dba_source
where name = '<PROCEDURE_NAME>'
and owner = '<PROCEDURE_OWNER>';
spool off

This gives the source code of the procedure/package. Edit as appropriate and
copy over to target DB

Hope this help

Titus Olowok
Oracle DBA
Atlanta, GA

----- Original Message -----
From: "Derrick Pitts "
<oracledba-ezmlmshield-x32389140.[Email address protected]
To: "LazyDBA Discussion" <[Email address protected]
Sent: Tuesday, August 31, 2004 4:15 PM
Subject: How to copy Procedure into a another DB.


> Gurus,
>
> What is the easiest way to copy a procedure into a different DB?
>
>
> --------
> website: http://www.LazyDBA.com
> Please don't reply to RTFM questions
> Oracle documentation is here: http://tahiti.oracle.com
> To unsubscribe: see http://www.lazydba.com/unsubscribe.html
> To subscribe: see http://www.lazydba.com
> By using this list you agree to these
> terms:http://www.lazydba.com/legal.html
>
>


--------
website: http://www.LazyDBA.com
Please don't reply to RTFM questions
Oracle documentation is here: http://tahiti.oracle.com
To unsubscribe: see http://www.lazydba.com/unsubscribe.html
To subscribe: see http://www.lazydba.com
By using this list you agree to these
terms:http://www.lazydba.com/legal.html


Oracle LazyDBA home page