不使用游标,多张表的多条记录更新

来源:互联网 发布:vue.js radio checked 编辑:程序博客网 时间:2024/06/05 16:36
BEGINFOR c IN (select distinct t2.name,t1.idfrom table1 t1,table2 t2where t1.id = t2.id)LOOPupdate table1 set name = c.name where id = c.id;END LOOP;END;

0 1