ORA-02292: integrity constraint with FK reference with same table PK

Hello Tom,

Need Ur help.

DB : 12.1.0.2.0

While execution script we are facing below issue:

— Table have PK and FK (FK refer to same table PK).

While we execute script for delete some data , But some how we get the error of

ORA-02292: integrity constraint (CRESTELSYSTEMCRESTEL62308.FK_ACTION_ACTION_1) violated – child record found

This is the query:

delete from TBLMACTION WHERE SCREENID IN ( SELECT SCREENID FROM TBLSSCREEN where alias=’PRODUCT_MANAGER’)


This is the Table structure:

CREATE TABLE “TBLMACTION”

( “ACTIONID” CHAR(8 BYTE),

“NAME” VARCHAR2(100 BYTE),

“SCREENID” CHAR(6 BYTE),

“ALIAS” VARCHAR2(50 BYTE),

“DESCRIPTION” VARCHAR2(255 BYTE),

“ACTIONTYPEID” CHAR(5 BYTE),

“PARENTACTIONID” CHAR(8 BYTE),

“ACTIONLEVEL” NUMBER(2,0),

“SYSTEMGENERATED” CHAR(1 BYTE),

“MODULE” VARCHAR2(100 BYTE),

“LINK” VARCHAR2(255 BYTE),

“ACTIONCLASS” VARCHAR2(200 BYTE),

“DISPLAYORDER” NUMBER(*,0) DEFAULT 0,

“HYPERLINKTYPE” VARCHAR2(20 BYTE) DEFAULT ‘FIXED’,

“AVPAIR” VARCHAR2(100 BYTE),

CONSTRAINT “NN_ANID_AN” CHECK (ACTIONID IS NOT NULL) ENABLE,

CONSTRAINT “NN_NAME_AN” CHECK (NAME IS NOT NULL) ENABLE,

CONSTRAINT “NN_SCREENID_AN” CHECK (SCREENID IS NOT NULL) ENABLE,

CONSTRAINT “NN_ALIAS_AN” CHECK (ALIAS IS NOT NULL) ENABLE,

CONSTRAINT “NN_ANTYPEID_AN” CHECK (ACTIONTYPEID IS NOT NULL) ENABLE,

CONSTRAINT “NN_ANLEVEL_AN” CHECK (ACTIONLEVEL IS NOT NULL) ENABLE,

CONSTRAINT “NN_SYGN_AN” CHECK (SYSTEMGENERATED IS NOT NULL) ENABLE,

CONSTRAINT “NN_MOD_AN” CHECK (MODULE IS NOT NULL) ENABLE,

CONSTRAINT “NN_DISPLAYORDER_AN” CHECK (DISPLAYORDER IS NOT NULL) ENABLE,

CONSTRAINT “PK_ACTION” PRIMARY KEY (“ACTIONID”),

CONSTRAINT “FK_ACTION_ACTION_1” FOREIGN KEY (“PARENTACTIONID”)

REFERENCES “TBLMACTION” (“ACTIONID”) ENABLE

) ;

We check data and all things,

Actually, Main Problem is that, Same script is successfully execute with oracle version 11.2.0.3 without any changes, But some how it is not execute with version 12.1.0.2.

Please let me know is there any related changes or BUG with 12c. Or I have to configure any parameter for same.

Related:

Leave a Reply