impdp error

classic Classic list List threaded Threaded
6 messages Options
Reply | Threaded
Open this post in threaded view
|

impdp error

Arsala

Sir

I want to export schema it exported without  errore

expdp system/XXXXXX schemas=SIGTASAD directory=backup dumpfile=SIG.dmp logfile expdpsh.log;


when I import it give error  like below

impdp system/XXXXXX schemas=SIGTASAD directory=backup dumpfile=SIG.dmp logfile impdpsh.log;

Processing object type SCHEMA_EXPORT/TABLE/GRANT/OWNER_GRANT/OBJECT_GRANT
Processing object type SCHEMA_EXPORT/TABLE/INDEX/INDEX
ORA-39083: Object type INDEX failed to create with error:
ORA-01452: cannot CREATE UNIQUE INDEX; duplicate keys found
Failing sql is:
CREATE UNIQUE INDEX "SIGTASAD"."CORP_REG_NAME_FK_I" ON "SIGTASAD"."CORPORATION" ("REGIST_NAME") PCTFREE 10 INITRANS 2 MAXTRANS 255  STORAGE(INITIAL 1048576 NEXT 1048576 MINEXTENTS 1 MAXEXTENTS 2147483645 PCTINCREASE 0 FREELISTS 1 FREELIST GROUPS 1 BUFFER_POOL DEFAULT FLASH_CACHE DEFAULT CELL_FLASH_CACHE DEFAULT) TABLESPACE "IRD_INDEXES" PARALLEL 1
ORA-39083: Object type INDEX failed to create with error:
ORA-01452: cannot CREATE UNIQUE INDEX; duplicate keys found
Failing sql is:
CREATE UNIQUE INDEX "SIGTASAD"."ESTAB2_UK" ON "SIGTASAD"."ESTABLISHMENT" ("ENTERPRISE_NO", "CITY_NO", "NAME", "ADDRESS", "STREET_NO", "PARCEL_NO") PCTFREE 10 INITRANS 2 MAXTRANS 255  STORAGE(INITIAL 2097152 NEXT 1048576 MINEXTENTS 1 MAXEXTENTS 2147483645 PCTINCREASE 0 FREELISTS 1 FREELIST GROUPS 1 BUFFER_POOL DEFAULT FLASH_CACHE DEFAULT CELL_FLASH_CACHE DEFAULT) TABLESPACE
ORA-39083: Object type INDEX failed to create with error:
ORA-01452: cannot CREATE UNIQUE INDEX; duplicate keys found
Failing sql is:
CREATE UNIQUE INDEX "SIGTASAD"."IND_TZ_REG_UK" ON "SIGTASAD"."INDIVIDUAL" ("NAT_CARD_ID", "TZ_REG_BOOK", "TZ_REG_PAGE") PCTFREE 10 INITRANS 2 MAXTRANS 255  STORAGE(INITIAL 65536 NEXT 1048576 MINEXTENTS 1 MAXEXTENTS 2147483645 PCTINCREASE 0 FREELISTS 1 FREELIST GROUPS 1 BUFFER_POOL DEFAULT FLASH_CACHE DEFAULT CELL_FLASH_CACHE DEFAULT) TABLESPACE "IRD_INDEXES" PARALLEL 1
Processing object type SCHEMA_EXPORT/TABLE/CONSTRAINT/CONSTRAINT
ORA-39083: Object type CONSTRAINT failed to create with error:
ORA-02299: cannot validate (SIGTASAD.IND_TZ_REG_UK) - duplicate keys found
Failing sql is:
ALTER TABLE "SIGTASAD"."INDIVIDUAL" ADD CONSTRAINT "IND_TZ_REG_UK" UNIQUE ("NAT_CARD_ID", "TZ_REG_BOOK", "TZ_REG_PAGE") USING INDEX PCTFREE 10 INITRANS 2 MAXTRANS 255  STORAGE(INITIAL 65536 NEXT 1048576 MINEXTENTS 1 MAXEXTENTS 2147483645 PCTINCREASE 0 FREELISTS 1 FREELIST GROUPS 1 BUFFER_POOL DEFAULT FLASH_CACHE DEFAULT CELL_FLASH_CACHE DEFAULT) TABLESPA
ORA-39083: Object type CONSTRAINT failed to create with error:
ORA-02299: cannot validate (SIGTASAD.ESTAB2_UK) - duplicate keys found
Failing sql is:
ALTER TABLE "SIGTASAD"."ESTABLISHMENT" ADD CONSTRAINT "ESTAB2_UK" UNIQUE ("ENTERPRISE_NO", "CITY_NO", "NAME", "ADDRESS", "STREET_NO", "PARCEL_NO") USING INDEX PCTFREE 10 INITRANS 2 MAXTRANS 255  STORAGE(INITIAL 2097152 NEXT 1048576 MINEXTENTS 1 MAXEXTENTS 2147483645 PCTINCREASE 0 FREELISTS 1 FREELIST GROUPS 1 BUFFER_POOL DEFAULT FLASH_CACHE DEFAULT CELL_FLAS
Processing object type SCHEMA_EXPORT/TABLE/INDEX/STATISTICS/INDEX_STATISTICS
ORA-39112: Dependent object type INDEX_STATISTICS skipped, base object type INDEX:"SIGTASAD"."IND_TZ_REG_UK" creation failed
ORA-39112: Dependent object type INDEX_STATISTICS skipped, base object type INDEX:"SIGTASAD"."ESTAB2_UK" creation failed
ORA-39112: Dependent object type INDEX_STATISTICS skipped, base object type INDEX:"SIGTASAD"."CORP_REG_NAME_FK_I" creation failed



Reply | Threaded
Open this post in threaded view
|

Re: impdp error

ErmanArslansOracleBlog
Administrator
This post was updated on .
Did you run this import multiple times? I m asking this, because some of the records may be left there and that's why reimporting may create duplicate records.

The error is obvious. There are duplicate records in the columns on which the impdp tries to create unique index (unique index requires unique records) If that's the case, please delete the imported schema, recreate it and then reimport.
Also, ensure that no application is operating on the table on which the impdp tries to create unique indexes.

Reply | Threaded
Open this post in threaded view
|

Re: impdp error

ErmanArslansOracleBlog
Administrator
Check the following note as well;

ORA-01452: cannot CREATE UNIQUE INDEX; duplicate keys found or silent corruption / rounding of the fractional seconds part of timestamp with timezone data during expdp/impdp (Doc ID 1608635.1)
Reply | Threaded
Open this post in threaded view
|

Re: impdp error

Arsala
In reply to this post by ErmanArslansOracleBlog

Thanks for guide

While I importing data if it give error then I recreate user,,

one my friend give me this script for export and import ..

exporting is don without errore

expdp system/aone@dwh directory=backup dumpfile=scott2.dmp logfile=scott2.log schemas=scott PARALLEL=4  flashback_time=to_timest
amp(to_char(systimestamp\,'mm/dd/yyyy\ hh24:mi:ss.ff9')\,'mm/dd/yyyy\ hh24:mi:ss.ff9')


but while we I import dumpfile it give errore like this.


impdp system/aone@dwh directory=backup dumpfile=scott2.dmp logfile=scott2.log schemas=scott PARALLEL=4  flashback_time=to_timest
amp(to_char(systimestamp\,'mm/dd/yyyy\ hh24:mi:ss.ff9')\,'mm/dd/yyyy\ hh24:mi:ss.ff9')



Connected to: Oracle Database 11g Enterprise Edition Release 11.2.0.1.0 - Production
With the Partitioning, OLAP, Data Mining and Real Application Testing options
ORA-39005: inconsistent arguments
ORA-39208: Parameter FLASHBACK_TIME is invalid for IMPORT jobs.





Reply | Threaded
Open this post in threaded view
|

Re: impdp error

ErmanArslansOracleBlog
Administrator
The error is clear.

flashback_time is not an import parameter.
Remove it from the command line
Reply | Threaded
Open this post in threaded view
|

Re: impdp error

ErmanArslansOracleBlog
Administrator
Also check the following document:
ORA-01452: cannot CREATE UNIQUE INDEX; duplicate keys found or silent corruption / rounding of the fractional seconds part of timestamp with timezone data during expdp/impdp (Doc ID 1608635.1)