Databases Reference
In-Depth Information
•
Interactive
Command
Interface
: This prompt is similar to the interactive
expdp
prompt, this allows you to manage and modify the parameters of a
running job.
•
Parameter
File
Interface
: This enables you to specify command-line
parameters in a parameter file. The
PARFILE
parameter must be specified in
the command line.
Remap function
One of the most interesting import data pump features is the
REMAP
function.
This function allows the user to easily redefine how an object will be stored in the
database. It allows us, amongst many other things, to specify if the tables to be
loaded will be remapped against another schema (
REMAP_SCHEMA
). It also changes
the tablespace where the segment will be stored (
REMAP_TABLESPACE
). In case of a
full data pump import, the function can also remap where the database files will be
created by means of the
REMAP_DATAFILE
keyword.
Let's show the
REMAP_SCHEMA
facility. It is common practice to have a user's schema
cloned for testing or development environments. So let's assume the
HR
schema is
to be used by a recently created
HRDEV
user, and it requires all the
HR
schema objects
mapped in its schema.
Create the
HRDEV
user. In this case the user
HRDEV
is created with the RESOURCE
role granted. This is only for demonstration purposes, you should only grant the
minimum required privileges for your production users.
SQL> create user HRDEV ident
2 identified by ORACLE
3 default tablespace USERS;
User created.
SQL> grant CONNECT, RESOURCE to HRDEV;
Grant succeeded.
Search WWH ::
Custom Search