What will happen when running these commands?

Examine these Data Pump commands to export and import objects from and to the same
database. The dba has not yet created users hr1 and oe1. Exhibit: What will happen when
running these commands?

Examine these Data Pump commands to export and import objects from and to the same
database. The dba has not yet created users hr1 and oe1. Exhibit: What will happen when
running these commands?

A.
impdp will create two users called hr1 and oe1 and import only the tables owned by hr
and oe schemas to ht1 and oe1 schemas, respectively.

B.
expdp will fail because no path has been defined for the dumpfile.

C.
expdp will succeed but impdp will fail because the users do not exist.

D.
inpdp will create two users called hr1 and oe1 and import all objects to the new schemas.

Explanation:



Leave a Reply 4

Your email address will not be published. Required fields are marked *


Alfredo

Alfredo

D

Test with duplicating test user
[oracle@srv-oda-np-0 ~]$ expdp system schemas=test dumpfile=test.dmp logfile=test.log directory=bioimdp

Export: Release 12.1.0.2.0 – Production on Thu May 26 09:53:09 2016

Copyright (c) 1982, 2014, Oracle and/or its affiliates. All rights reserved.
Password:

Connected to: Oracle Database 12c Enterprise Edition Release 12.1.0.2.0 – 64bit Production
With the Partitioning, Real Application Clusters, Automatic Storage Management, OLAP,
Advanced Analytics and Real Application Testing options
Starting “SYSTEM”.”SYS_EXPORT_SCHEMA_01″: system/******** schemas=test dumpfile=test.dmp logfile=test.log directory=bioimdp
Estimate in progress using BLOCKS method…

[oracle@srv-oda-np-0 ~]$ impdp system schemas=test dumpfile=test.dmp logfile=test.log directory=bioimdp remap_schema=test:test2

Import: Release 12.1.0.2.0 – Production on Thu May 26 09:53:55 2016

Copyright (c) 1982, 2014, Oracle and/or its affiliates. All rights reserved.
Password:

Connected to: Oracle Database 12c Enterprise Edition Release 12.1.0.2.0 – 64bit Production
With the Partitioning, Real Application Clusters, Automatic Storage Management, OLAP,
Advanced Analytics and Real Application Testing options
Master table “SYSTEM”.”SYS_IMPORT_SCHEMA_01″ successfully loaded/unloaded
Starting “SYSTEM”.”SYS_IMPORT_SCHEMA_01″: system/******** schemas=test dumpfile=test.dmp logfile=test.log directory=bioimdp remap_schema=test:test2
Processing object type SCHEMA_EXPORT/USER

[oracle@srv-oda-np-0 ~]$ sqlplus test2/test

SQL*Plus: Release 12.1.0.2.0 Production on Thu May 26 09:54:13 2016

Copyright (c) 1982, 2014, Oracle. All rights reserved.

Connected to:
Oracle Database 12c Enterprise Edition Release 12.1.0.2.0 – 64bit Production
With the Partitioning, Real Application Clusters, Automatic Storage Management, OLAP,
Advanced Analytics and Real Application Testing options

SQL> exit

Maxim

Maxim

C, you need to test once again with include=table, that’s the catch. There will be no metadata to create hr1 and oe1, so impdp will fail.