This is a silly little problem. I have a large table with hundreds of columns, so I don't want to write out each column name individually. The problem is that say, table1
is the source table, with 200 columns, and table2
is the destination table with 201 columns, where the last column of table2
is an extra auto-increment (primary key) column. The idea is that I simply can do
insert into table2 select * from table1 where row = ##;
and I would wish that all the data would be copied and the auto-increment column would just do its job. However I get this pesky error message:
Error Code: 1136. Column count doesn't match value count at row 1
Anyone have a simple solution to this?