gpt4 book ai didi

mysql - SQL错误1062 : Primary key problems

转载 作者:行者123 更新时间:2023-11-29 21:20:03 24 4
gpt4 key购买 nike

我的代码:

insert into userEmail ( userEmailId, userId, userEmail, userEmailTypeId )
values ('1005', 'a1a2', 'Dberkeley@fullsail.edu', '1');

我明白了......

19:06:22 insert into userEmail ( userEmailId, userId, userEmail, userEmailTypeId ) values ('1005', 'a1a2', 'Dberkeley@fullsail.edu', '1') Error Code: 1062. Duplicate entry '1005' for key 'PRIMARY' 0.00033 sec

最佳答案

这意味着您有一条 userEmailId 为 1005 的记录。

SELECT * 
FROM userEmail
WHERE userEmailId=1005

如果上面的查询返回一行,那就是你的证据。

关于mysql - SQL错误1062 : Primary key problems,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/35760711/

24 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com