mysql insert into 多条数据
2020-04-27 本文已影响0人
小蓝田
mysql 使用 insert into 语句时报错:
1136 - Column count doesn't match value count at row 1
报错语句样式如下:
insert into table1 select a.id,a.name from table2 a where a.name='t';
修改为如下即可:
insert into table1 (id,name) select a.id,a.name from table2 a where a.name='t';