Pregunta

I am trying to take a schema from an existing database and place it in a new database.

I've created dependant tablespaces for the data and everything seems to work ok except any tables with XMLTYPE columns error and fail with the error message below. The XMLTYPE are unvalidated CLOBs

KUP-11007: conversion error loading table "SCHEMA"."TABLE_NAME"
ORA-01400: cannot insert NULL into (XML_COLUMN)
KUP-11009: data for row: XML_COLUMN : 0X''

Some investigation seemed to indicate that using TABLES=TABLE_NAME instead of SCHEMA=SCHEMA would help but I have had no such luck.

Note that there are no constraints on this column and that some data could indeed be null (though after the import I get 0 of my several million records)

The command I am using to initiate the datapump is:

impdp TABLES=SCHEMA.TABLE_NAME DIRECTORY=DATA_PUMP_DIR DUMPFILE=oracledpexport.dmp LOGFILE=LOGFILE.LOG TABLE_EXISTS_ACTION=REPLACE
¿Fue útil?

Solución

We have been facing some problems during ORACLE import process.

The IMPDP process was not able to import tables containing XML data types. The reason for this is due to a bug in ORACLE 11g R1 version.

The work around for this is to use EXP process to create a dump instead of EXPDP. For a permanent fix, we have to explicitly save XML Type columns as CLOB

Also, Oracle has confirmed that this issue has been fixed in ORACLE 11gR2 version.

Licenciado bajo: CC-BY-SA con atribución
No afiliado a StackOverflow
scroll top