Monday, November 25, 2024

Table import and export.

Create Data Pump Directory.

The first step in Oracle Data Pump is to create an OS level directory which will be used by Oracle for performing exports and imports. Create directory at OS level

mkdir -p /u02/export_dir

Create directory inside the database

CREATE OR REPLACE DIRECTORY export_dir AS '/u02/ranesh';

Grant Permission

GRANT READ, WRITE ON DIRECTORY /u02/ranesh TO APPS;

View the directories.

Select * from dba_directories.

 Table Export and Import

 expdp apps/*****@Test  tables=emp  directory=export_dir  dumpfile=emp_1.dmp logfile=expdpemp_1.log

 check if the directories exist in the Target location.

 Import the table.

impdp apps/*****@Test  tables=emp  directory=export_dir  dumpfile=emp_1.dmp logfile=impdpemp_1.log

 


No comments:

Table import and export.

Create Data Pump Directory. The first step in Oracle Data Pump is to create an OS level directory which will be used by Oracle for perform...