I have disabled a constraint on a table as seen below:-
SELECT OWNER, CONSTRAINT_NAME , CONSTRAINT_TYPE ,
TABLE_NAME, STATUS, DEFERRABLE, DEFERRED, VALIDATED, GENERATED
FROM USER_CONSTRAINTS WHERE TABLE_NAME='AUTH_USER'
AND CONSTRAINT_NAME = 'XPKAUTH_USER'
/
OWNER CONSTRAINT_NAME
C TABLE_NAME STATUS DEFERRABLE DEFERRED
VALIDATED GENERATED
------------------------------
------------------------------ - ------------------------------ --------
-------------- --------- ------------- --------------
ORDER_SCHEMA XPKAUTH_USER
P AUTH_USER DISABLED NOT DEFERRABLE IMMEDIATE NOT
VALIDATED USER NAME
However, when inserting data into the table, I am getting message for
the same constraint getting violated.
Why is this happening?
SQL> insert into AUTH_USER
2 (
3 user_id,
4 status,
5 nt_auth_id,
6 forms_auth_id,
7 create_date,
8 modify_date,
9 update_by,
10 update_system,
11 update_db_username,
12 UPDATE_HOSTNAME,
13 UPDATE_OSUSER
14 )
15 select
16 user_id,
17 status,
18 nt_auth_id,
19 forms_auth_id,
20 create_date,
21 modify_date,
22 update_by,
23 update_system,
24 update_db_username,
25 UPDATE_HOSTNAME,
26 UPDATE_OSUSER
27 from order_schema.AUTH_USER@obcrpprod_node1.world;
insert into AUTH_USER
*
ERROR at line 1:
ORA-00001: unique constraint (ORDER_SCHEMA.XPKAUTH_USER)
violated