Database Utilities (MOSC)

MOSC Banner

m trDatapump but some tables just with metadata only

edited Dec 9, 2019 8:55PM in Database Utilities (MOSC) 4 commentsAnswered ✓

I want to export a database as a particular schema, but need to exclude data of some tables. I was planning on using the following: But a number of tables contain triggers and constraints, this seems to case issues when trying to do metadata first and then data second. The triggers are not created.

expdp user/pass directory=mydir dumpfile=mydumpfile.dmp log=mylog.txt content=metadata_only exclude=triggers,constraints

expdp user/pass directory=mydir dumpfile=mydumpfile.dmp log=mylog.txt content=data_only

once the metadata is loaded, then import the data

impdp user/pass directory=mydir dumpfile=mydumpfile.dmp log=mylog.txt content=metadata_only

Howdy, Stranger!

Log In

To view full details, sign in to My Oracle Support Community.

Register

Don't have a My Oracle Support Community account? Click here to get started.

Category Leaderboard

Top contributors this month

New to My Oracle Support Community? Visit our Welcome Center

MOSC Help Center