Help - Search - Members - Calendar
Full Version: Data pump import - replace existing objects
Oracle DBA Forums > Oracle > Oracle Forum
I'm wanting to do a datapump schema import such that all existing objects are replaced.

I see the table_exists_action parameter, but this seems only to apply to tables - when I set to REPLACE, tables are replaced, but other objects, such as packages are not. This leaves me with an inconsistent schema.

Can I replace all objects with data pump? Or do I need to generate a script to delete objects prior to import?

Sorry if I've missed something obvious - fairly new to this.

I've always been a fan of dropping the user before import myself to ensure that everything is clean.

I *think* packages are 'created or replaced' so they would get updated, but old packages that are no longer needed would stick around, etc etc.
It doesn't look as though any non-table object is replaced if it already exists.

I don't have privilege to drop the user, but I will drop objects (packages, sequences, procs, funcs etc) instead.

Seems like a bit of missing functionality in datapump (though I appreciate there is a lot of new functionality added over imp/exp)

There is nothing inconsistent about it at all. The user still exists, so why should objects not involved in the import be affected? That's like saying you can never import part of a schema (e.g., a table) because there will be other objects in place. If you want all objects removed, then either remove all of them ahead of time, or drop the user cascade (and if you're re-creating the user).
This is a "lo-fi" version of our main content. To view the full version with more information, formatting and images, please click here.
Invision Power Board © 2001-2016 Invision Power Services, Inc.