Wrong Error ORA-2291 With SQL*Loader And Import (IMP) When Trigger Exists On Target Table
(Doc ID 1504013.1)
Last updated on MAY 18, 2021
Applies to:
Oracle Database - Enterprise Edition - Version 11.1.0.6 to 11.2.0.2 [Release 11.1 to 11.2]Oracle Database Cloud Schema Service - Version N/A and later
Oracle Database Exadata Express Cloud Service - Version N/A and later
Gen 1 Exadata Cloud at Customer (Oracle Exadata Database Cloud Machine) - Version N/A and later
Oracle Cloud Infrastructure - Database Service - Version N/A and later
Information in this document applies to any platform.
Symptoms
During loading (SQL*Loader) or importing (IMP) data into a detail table referencing a parent table you receive the error:
ORA-2291: integrity constraint (TEST.B_TAB_FK) violated - parent key not found
related to good records which exist in parent table.
The next examples (SQL*Loader and IMP) demonstrate this:
1. Using SQL*Loader (SQLLDR)
=> The detail rows:
Column 1 D
Column 2 1
Column 3 1
Column 4 Detail 1 line 1
Column 1 D
Column 2 1
Column 3 2
Column 4 Detail 1 line 2
Column 1 D
Column 2 1
Column 3 3
Column 4 Detail 1 line 3
are correct but are rejected with wrong error ORA-2291.
Changes
Cause
To view full details, sign in with your My Oracle Support account. |
|
Don't have a My Oracle Support account? Click to get started! |
In this Document
Symptoms |
Changes |
Cause |
Solution |
References |