here's the scenario:
say i have tables A and B (id, name, C_id), both have a foreign key reference to table C (A_or_B_id, foo)
in the interest of normalization, i'm consolidating A and B into a new table X. obviously i cannot preserve the key id from one of the tables, let it be table B, since they would overlap with those from A.
the problem is now how to update table C with the new id from X? as far as i can tell, the reference from B is broken, so i cannot use a join.
any ideas? i might just resort to writing a php script to do it.
-jeff
try { succeed(); } catch(E) { tryAgain(); } finally { rtfm(); }
i like your sleeves...they're real big
say i have tables A and B (id, name, C_id), both have a foreign key reference to table C (A_or_B_id, foo)
in the interest of normalization, i'm consolidating A and B into a new table X. obviously i cannot preserve the key id from one of the tables, let it be table B, since they would overlap with those from A.
the problem is now how to update table C with the new id from X? as far as i can tell, the reference from B is broken, so i cannot use a join.
any ideas? i might just resort to writing a php script to do it.
-jeff
try { succeed(); } catch(E) { tryAgain(); } finally { rtfm(); }
i like your sleeves...they're real big