mysql里常见报错信息_MySQL 常见报错信息整理

1.ERROR 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 'love China' at line 1

语法错误

2.ERROR 1007 (HY000): Can't create database 'ilovechina'; database exists

数据库已存在

3.ERROR 1008 (HY000): Can't drop database 'ilovachina';database doesn't exist

数据库不存在

4.ERROR 1049 (42000):Unknown database 'database'

数据库不识别

5.ERROR 1046 (3D000): No database selected

没有选中数据库

6.ERROR 1113 (42000):A table must have at least 1 column

数据表至少要有一列

7.ERROR 1146 (42S02): Table 'ishop1.cuetomer' doesn't exist

数据表"cuetomer" 在数据库“ishop1"中不存在

8.ERROR 1062 (23000): Duplicate entry '2' for key 'PRIMARY'

输入的2违反主键约束

9.ERROR 1136 (21S01): Column count doesn't match value count at row 2

输入行内值的计数与列计数不匹配

10.ERROR 1054 (42S22): Unknown column 'ct_num' in 'field list'

字段列表中存在未知列"ct_num"

11.ERROR 1051 (42S02): Unknown table 'myschool.subjedt'

数据库myschool中存在未知表"subjedt"

12.ERROR 1366 (HY000): Incorrect integer value: '初一' for column 'id' at row 1

id列第一行输入的“初一”数据类型错误

13.ERROR 1452 (23000): Cannot add or update a child row: a foreign key constraint fails (`myschool`.`gg`, CONSTRAINT `gg_ibfk_1` FOREIGN KEY (`grand_id`) REFERENCES `grand` (`id`))

违反外键约束,不能新增或更新子行数据

14.ERROR 1215 (HY000): Cannot add foreign key constraint

不能创建外键约束

15.ERROR 1111 (HY000): Invalid use of group function

函数无效

16.ERROR 1048 (23000): Column 'cu_phone' cannot be null

cu_phone 列不能为空

17.ERROR 1242 (21000): Subquery returns more than 1 row

子查询返回超过1行

18.ERROR 1235 (42000): This version of MySQL doesn't yet support 'LIMIT & IN/ALL/ANY/SOME subquery'

版本不支持

19.ERROR 1630 (42000): FUNCTION o.sum does not exist. Check the 'Function Name Parsing and Resolution' section in the Reference Manual

函数不存在

20.ERROR 1241 (21000): Operand should contain 1 column(s)

操作数应该包含1列

21.ERROR 1451 (23000): Cannot delete or update a parent row: a foreign key constraint fails (`ishop1`.`order`, CONSTRAINT `fk_3` FOREIGN KEY (`o_cid`) REFERENCES `commodity` (`c_id`))

不能删除或更新父行

22.ERROR 1292 (22007): Incorrect date value: '2002' for column 'dep_date' at row 1

不正确的日期值

23.ERROR 1060 (42S21): Duplicate column name 'c_id'

重复专栏的名字c_id

24.ERROR 1066 (42000): Not unique table/alias: 'customer'

'customer'不是唯一的表名/别名

25.ERROR 1065 (42000): Query was empty

查询为空

26.ERROR 1052 (23000): Column 'sid' in field list is ambiguous

SID列不明确

27.ERROR:DELIMITER must be followed by a 'delimiter' character or string

'delimiter' 后面必须有一个字符或者字符串

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值