> 1136 - Column count doesn't match value count at row 1
时间: 2023-10-21 10:34:10
浏览: 103
This error message is typi[call](https://geek.csdn.net/educolumn/3cda1aeab044ec99e05646be0d6f9d8e?spm=1055.2569.3001.10083)y encountered when [insert](https://geek.csdn.net/educolumn/54b8fe5f2aac0d59a4b7b189ca99a7bd?spm=1055.2569.3001.10083)ing data into a table and the number of columns in the [insert](https://geek.csdn.net/educolumn/54b8fe5f2aac0d59a4b7b189ca99a7bd?spm=1055.2569.3001.10083) statement does not match the number of values being [insert](https://geek.csdn.net/educolumn/54b8fe5f2aac0d59a4b7b189ca99a7bd?spm=1055.2569.3001.10083)ed.
For example, if a table has three columns (id, name, age) and an INSERT statement tries to insert data for only two columns (id, name) l[ike](https://geek.csdn.net/educolumn/4654d38702ca9c29a51957a5f9fc9ed5?spm=1055.2569.3001.10083) this:
INSERT INTO table_name (id, name) VALUES (1, 'John');
The error message "Column count doesn't match value count at row 1" will be displayed because there is a mismatch between the number of columns and values in the INSERT statement.
To fix this error, ensure that the number of columns and values in the INSERT statement match the structure of the table.