Page 1 of 1

issues with a generic job for update foreign key of tables

Posted: Tue Aug 12, 2008 9:01 pm
by jenny_wang
hi,all
in the database, there are some tables which have foreign keys, and the tables the foreign keys reference will keep all historial records(if a record is updated, the older one is marked as 'O', the lastest is marked as 'N', and there is a column to identify the same record), now i wanna update all old foreign keys to the lastest one. i wanna create a generic job to update all tables which have such foreign keys, but the number of foreign keys is different in different table. now what i can do is create a job update only one column. do someone have better idea to design the job?

Thanks!