0

We have an old DB server, running Oracle 11g on Solaris.

We also have a new DB server, also running Oracle 11g, but on RHEL.

We want to move a schema to the new db - but we need everything it refers to moved too. The data /tables can be moved easily enough, but then there's sequences, stored procedures, db types, views and maybe other things I'm not aware of yet.

The original schema contains different objects assigned to specific tablespaces and we need the same assignments in the destination server too.

What's the best way to accomplish this?

It looks like expdp/impdp can export and import other object types, but I can't find a list of the types to include, or how to say "everything".

Also DBMS_METADATA.GET_DDL looks useful, but again I can only find examples for specific object types and I want "everything in the schema", ideally.

Paul

asked Dec 17, 2014 at 9:36
5
  • Hmm. The answer may involve DBMS_METADATA.GET_DDL but I'm not sure yet. Commented Dec 17, 2014 at 9:45
  • I'd say, flag your question to move to dba.stackexchange. You might get a better response there. Commented Dec 17, 2014 at 9:48
  • Yep. I wasn't aware of that one. Will it move immediately? Otheriwse I should delete this one and create a new one there. Commented Dec 17, 2014 at 9:50
  • AFAIK you still need a moderator to move your question (or a peer review has to happen on the flag). Probably easier to delete and recreate. Commented Dec 17, 2014 at 9:51
  • Probably is a duplicate of this one, which I didn't spot before: dba.stackexchange.com/questions/30516/… Commented Dec 17, 2014 at 11:26

1 Answer 1

2

Datapump is one answer.

Look at http://docs.oracle.com/cd/E11882_01/server.112/e22490/dp_export.htm#i1007524 - specifically "Transportable Table mode". Moves the metadata, but not the data. You can choose which schemas to include with the SCHEMAS switch, along with the INCLUDE/EXCLUDE parameters.

answered Dec 17, 2014 at 14:19
1
  • Thanks. The duplicate question also answers this. We're trying datapump right now. Commented Dec 17, 2014 at 14:26

Your Answer

Draft saved
Draft discarded

Sign up or log in

Sign up using Google
Sign up using Email and Password

Post as a guest

Required, but never shown

Post as a guest

Required, but never shown

By clicking "Post Your Answer", you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.