将表2的数据插入到表1
语法:
insert into 表1(插入字段)select 插入字段 from 表2 where ...
实战例子:
INSERT INTO 表1 (syncid,syncdes,tablename,keyfields,syncfields,version,serialno)
select syncid,syncdes,tablename,keyfields,syncfields,version,serialno from 表2 where syncid=#{syncid}
版权声明:本文为weixin_43110289原创文章,遵循CC 4.0 BY-SA版权协议,转载请附上原文出处链接和本声明。