Mysql update table if field exists

Submitted by Anonymous (not verified) on Mon, 07/20/2009 - 22:45

I am searching -google, mysql-man, forums- for a solution for more than four hours but could not find anything. I need simply a function+
condition to update hundreds of tables.

This query stopped on first error:

update ignore table1 set id2=id1;
update ignore table2 set id2=id1;
...

Any idea?