Q
Problem solve Get help with specific problems with your technologies, process and projects.

Exporting packages from production to test database

How do I export packages contained in my production database to my test database?

How do I export packages contained in my production database to my test database?
Use the DBMS_METADATA.GET_DDL function to generate the CREATE statement. Spool the output to a file which can then be run on your test database. For instance:
SELECT DBMS_METADATA.GET_DDL(owner,object_name,object_type)
FROM user_objects WHERE object_type='PACKAGE';
If you save the output in a file (with the SPOOL command in SQL*Plus) you now have a script to run on any other database.

Dig Deeper on Oracle database design and architecture

Have a question for an expert?

Please add a title for your question

Get answers from a TechTarget expert on whatever's puzzling you.

You will be able to add details on the next page.

Start the conversation

Send me notifications when other members comment.

Please create a username to comment.

-ADS BY GOOGLE

SearchDataManagement

SearchBusinessAnalytics

SearchSAP

SearchSQLServer

TheServerSide.com

SearchDataCenter

SearchContentManagement

SearchHRSoftware

Close