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!

Updating Primary Key Records and Related FK dependencies

729133Oct 20 2009 — edited Oct 21 2009
1) How can I found out the name of all the tables that are using my primary key as foreign keys? The primary key is a varchar & used in many other tables. Now the PK records must be changed per client request, so it will obviously affect all my dependent tables.
2) What is the most efficient PL/SQL script to perform this procedure?
Any suggestions will be helpful.

For testing I think I'd like a list of all the tables followed by a list of all the records affected. This report should display the PK record & all dependency records requiring an update. Is this reasonable?
This post has been answered by Centinul on Oct 20 2009
Jump to Answer
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Nov 18 2009
Added on Oct 20 2009
4 comments
565 views