Skip to Main Content

SQL & PL/SQL

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

Enable / Disable Constraints.

879380Aug 1 2011 — edited Aug 1 2011
Hi,

I am using Oracle 11g, i am still in the learning curve in pl sql where i got an strange situation regarding constraints disable / enable ,

While moving datas(insert scripts from source) to the table(another copy of source) usually i will disable all the foregin constraints and enable it .

While enableing the foregin constraints i got the error of ''Parent key not found".

ALTER TABLE suppliers enable CONSTRAINT check_supplier_id;

this can be over come by using the below query.

'alter table '|| i.table_name|| ' MODIFY constraint '|| i.constraint_name|| ' ENABLE NOVALIDATE ';

The question is the source contains the data properly but after moving the datas into destination enabling the constraints gives the error.(Need an solution for this )

Thanks
Parthiban Kumar
This post has been answered by 647939 on Aug 1 2011
Jump to Answer
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Aug 29 2011
Added on Aug 1 2011
3 comments
2,019 views