找回密码
 注册
查看: 2757|回复: 0

ERROR 1136 (21S01): Column count doesn't match value count at row 1 数据库插入数据自动增长

[复制链接]

1

主题

0

回帖

12

积分

管理员

积分
12
QQ
发表于 2020-6-18 09:50:19 | 显示全部楼层 |阅读模式
mysql> insert into jjj values("yang","23"),("ya","22");# G' M4 s! e' c& ~
ERROR 1136 (21S01): Column count doesn't match value count at row 1
4 R2 Q/ Q5 P% W7 i$ pmysql> alter table jjj modify id int(11) auto_increment;
* X: f! W+ ?) P6 f( P& PQuery OK, 0 rows affected (0.16 sec)
' B, J0 _% D, z+ KRecords: 0  Duplicates: 0  Warnings: 0
+ E8 }1 N. t7 W2 x& x) _mysql> insert into jjj values("yang","23"),("ya","22");
7 u% U4 N; k* a: p- d# h9 iERROR 1136 (21S01): Column count doesn't match value count at row 1
8 r4 Q( N% a! }" w5 f1 a$ Gmysql> insert into jjj values(,"yang","23"),(,"ya","22");
& ?+ @% B  B1 Y4 hERROR 1064 (42000): You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '"yang","23"),(,"ya","22")' at line 1- x4 U( Y. s$ W: m
mysql> insert into jjj values(" ","yang","23"),(" ","ya","22");" l  n0 u7 X3 h
Query OK, 2 rows affected, 2 warnings (0.11 sec)
" T9 j( [. y; r- F: K6 l" oRecords: 2  Duplicates: 0  Warnings: 2
6 R/ g8 H4 P9 G3 a2 T- M" Imysql> select * from jjj;+ j$ A7 m  E% o0 b) o
+----+------+------+1 R4 P+ Y8 S  P
| id | name | age  |
4 Q, x% N+ b' F3 P+----+------+------+
- |+ g7 Z5 X, l4 l|  1 | yang |   23 |: L/ T& Z, h6 g! M) e: h
|  2 | ya   |   22 |
$ J2 @  e6 s3 t' z; D" {9 S+----+------+------+6 _5 P  y3 w5 `  }: r
2 rows in set (0.00 sec)9 Q/ d- o5 ]* H  G& }0 b
mysql> 2 B& G: }' p; }! E6 G
您需要登录后才可以回帖 登录 | 注册

本版积分规则

返回首页|Archiver|手机版|小黑屋|易陆发现技术论坛 ( 蜀ICP备2026014127号-1 )

GMT+8, 2026-6-12 01:29 , Processed in 0.017593 second(s), 22 queries .

Powered by Discuz! X5.0

© 2001-2026 Discuz! Team.

快速回复 返回顶部 返回列表