ORA-947 Error Thrown for Enable Table Constraint when using Exceptions Into Clause
(Doc ID 2126643.1)
Last updated on JANUARY 09, 2020
Applies to:Oracle Database - Enterprise Edition - Version 22.214.171.124 and later
Oracle Database Cloud Schema Service - Version N/A and later
Oracle Database Exadata Express Cloud Service - Version N/A and later
Oracle Database Exadata 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.
A table was created to hold exceptions that would be generated when enabling constraints on existing tables:
CREATE TABLE "OWNER"."EXCEPTIONS_TABLE_NAME"
( "ROW_ID" ROWID,
"OWNER" VARCHAR2(30 CHAR),
"TABLE_NAME" VARCHAR2(30 CHAR),
"CONSTRAINT" VARCHAR2(30 CHAR)
When trying to enable constraints for any of the existing tables by using:
ALTER TABLE <any table> ENABLE CONSTRAINT <constraint_name> EXCEPTIONS INTO <owner.exceptions_table_name>
ORA-947 error was thrown:
SQL Error: ORA-00604: error occurred at level 1 recursive SQL
ORA-00947: not enough values
Where as , a simple enable constraint would succeed.
ALTER TABLE <any table> ENABLE CONSTRAINT <constraint_name>
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