Drop foreign key constraint

SQL ERROR: ORA-04021: timeout occurred while waiting to lock object.
lium1Asked:
Who is Participating?

Improve company productivity with a Business Account.Sign Up

x
 
QlemoConnect With a Mentor Batchelor, Developer and EE Topic AdvisorCommented:
Since you want to have the FK validated, it needs to go thru both this and the referred table to check the constraint. You won't get that to succeed for heavy used tables (when updating/inserting a lot).
Not requesting validation is one option. Better to check manually later for mismatches - you'll have to correct them anyway, and it is better to have the FK ensured for future changes than not at all.
0
 
QlemoBatchelor, Developer and EE Topic AdvisorCommented:
The corresponding table could not be locked within the time allowed.
0
 
lium1Author Commented:
I meant how to solve this issue. I am trying to add constraint foreign_key with enable and validate where I got an timeout error.
0
 
QlemoBatchelor, Developer and EE Topic AdvisorCommented:
"You can't do that" can be a valid and appropriate answer. If there is no way, there is none.
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.