Note that schema, table and column names are changed for security reasons.

Immediately I verified the column C1 in TEST table and observed that it is defined as NOT NULL. Intially, I thought this might be the reason for the error that Oracle is trying to insert NULL value. I checked in the production database and found that there is no NULL values at all in C1 column which means the table structure, data everything is perfect.

After referring to MOS doc 826746.1, got to know that this is a known issue when you take export with exp command from 11gR1 onwards using DIRECT=Y option.

This is because there is behaviour change in exp utility. Prior to 11gR1 when you take export (exp) with DIRECT=Y, if a NULL value is there in column, Oracle used to replace that with default value what it will have in COL$ table. But, from 11gR1 onwards, the value is not replaced by its default but the NULL values is stored in export dump. This will produce ORA-1400 during import.

The solution for this problem is simple…. take the export in conventinal path only i.e don’t use DIRECT=Y or use datapump for your activity.

Even though it seems to be a problem, Oracle has not opened any bug on this because exp utility is desupported from 11g onwards and Oracle recommends to use datapump only.

Finally, i temporarily fixed the issue by taking TEST table export in expdp. Also, changed the daily export backup method from exp to expdp in the production database.