Reverse query to find Foreign Key
Date: Wed, 29 Oct 2008 00:29:17 -0700 (PDT)
I have a ID primary key that is used across many tables as fk, I want to find a sql (run as sysadmin) that can find all tables who have that id as fk and change it to something else, maintaining all constraints and ref integrity etc. i.e. I want to change the fk value in all tables to something other pk.
is there a simple query to do this?
thanks Received on Wed Oct 29 2008 - 02:29:17 CDT