1、update a inner join b on a.id=b.id set a.name=b.name where ...
 
2、update table1 set a.name = b.name from table1 a inner join table2 b on a.id =b.id where...

相关文章: