O'Reilly logo

Oracle Database 12c Backup and Recovery Survival Guide by Aman Sharma, Francisco Munoz Alvarez

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Cloning a user

In the past when a DBA had the need to create a new user with the same structure (all objects, tablespaces quota, synonyms, grants, system privileges, and so on) using the old exp/imp, it was a very painful experience. This is because not all the metadata was included, and it was a very slow process when moving a big volume of data. Now this can be done very easily using Data Pump. Let's use an example where you want to create the user TEST2 exactly like the user TEST. In order to achieve this goal, all you will need to do is first export the schema TEST definition, and then import it again asking the Data Pump to change the schema TEST for the new schema named TEST2 using the REMAP_SCHEMA parameter available with impdp:

$ expdp ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required