What's wrong?
clliranJun 30 2010 — edited Jul 2 2010Hi everybody,
I'm learning impdp and expdp utilities. I've done some experiments with Express Edition and getting error.
Sequence of steps i have done:
CONN sys/password@XE AS SYSDBA
GRANT CREATE ANY DIRECTORY TO hr;
CREATE OR REPLACE DIRECTORY test_dir AS 'c:\test';
GRANT READ, WRITE ON DIRECTORY test_dir TO hr;
First i want to have dump of one table - hr.employees
i run this command in command line:
expdp hr/hr@XE tables=employees directory=test_dir dumpfile=expfirst.dmp logfile=expfirst.log
expdp hr/hr@XE tables=employees directory=tes
t_dir dumpfile=expfirst.dmp logfile=expfirst.log
Export: Release 10.2.0.1.0 - Production on Wednesday, 30 June, 2010 9:32:07
Copyright (c) 2003, 2005, Oracle. All rights reserved.
Connected to: Oracle Database 10g Express Edition Release 10.2.0.1.0 - Productio
n
Starting "HR"."SYS_EXPORT_TABLE_01": hr/********@XE tables=employees directory=
test_dir dumpfile=expfirst.dmp logfile=expfirst.log
Estimate in progress using BLOCKS method...
Processing object type TABLE_EXPORT/TABLE/TABLE_DATA
Total estimation using BLOCKS method: 64 KB
Processing object type TABLE_EXPORT/TABLE/TABLE
Processing object type TABLE_EXPORT/TABLE/GRANT/OWNER_GRANT/OBJECT_GRANT
Processing object type TABLE_EXPORT/TABLE/INDEX/INDEX
Processing object type TABLE_EXPORT/TABLE/CONSTRAINT/CONSTRAINT
Processing object type TABLE_EXPORT/TABLE/INDEX/STATISTICS/INDEX_STATISTICS
Processing object type TABLE_EXPORT/TABLE/COMMENT
Processing object type TABLE_EXPORT/TABLE/CONSTRAINT/REF_CONSTRAINT
Processing object type TABLE_EXPORT/TABLE/TRIGGER
Processing object type TABLE_EXPORT/TABLE/STATISTICS/TABLE_STATISTICS
. . exported "HR"."EMPLOYEES" 15.76 KB 107 rows
Master table "HR"."SYS_EXPORT_TABLE_01" successfully loaded/unloaded
******************************************************************************
Dump file set for HR.SYS_EXPORT_TABLE_01 is:
C:\TEST\EXPFIRST.DMP
Job "HR"."SYS_EXPORT_TABLE_01" successfully completed at 09:32:41
in this catalog c:\tes were created dump and log file. Then i deleted some rows from hr.employees. After that i dicided to import my dump file to get back my deleted rows. But i get error message. I dont know what i did wrong.
impdp hr/hr@XE tables=employees directory=tes
t_dir dumpfile=expfirst.dmp logfile=impfirst.log
Import: Release 10.2.0.1.0 - Production on Wednesday, 30 June, 2010 9:37:40
Copyright (c) 2003, 2005, Oracle. All rights reserved.
Connected to: Oracle Database 10g Express Edition Release 10.2.0.1.0 - Productio
n
Master table "HR"."SYS_IMPORT_TABLE_01" successfully loaded/unloaded
Starting "HR"."SYS_IMPORT_TABLE_01": hr/********@XE tables=employees directory=
test_dir dumpfile=expfirst.dmp logfile=impfirst.log
Processing object type TABLE_EXPORT/TABLE/TABLE
ORA-39151: Table "HR"."EMPLOYEES" exists. All dependent metadata and data will b
e skipped due to table_exists_action of skip
Processing object type TABLE_EXPORT/TABLE/TABLE_DATA
Processing object type TABLE_EXPORT/TABLE/GRANT/OWNER_GRANT/OBJECT_GRANT
Processing object type TABLE_EXPORT/TABLE/INDEX/INDEX
Processing object type TABLE_EXPORT/TABLE/CONSTRAINT/CONSTRAINT
Processing object type TABLE_EXPORT/TABLE/INDEX/STATISTICS/INDEX_STATISTICS
Processing object type TABLE_EXPORT/TABLE/COMMENT
Processing object type TABLE_EXPORT/TABLE/CONSTRAINT/REF_CONSTRAINT
Processing object type TABLE_EXPORT/TABLE/TRIGGER
Processing object type TABLE_EXPORT/TABLE/STATISTICS/TABLE_STATISTICS
Job "HR"."SYS_IMPORT_TABLE_01" completed with 1 error(s) at 09:37:45
Regards,
rustam