2024-06-09
閱讀量:
7579
sql 執(zhí)行update修改字段報錯
Hi 各位大神,
我的mysql執(zhí)行字段修改時,報錯信息如下
,麻煩幫忙看看原因,謝謝
18:05:54 update stu set s_sex='男' where s_sex='未知' Error Code: 1175. You are using safe update mode and you tried to update a table without a WHERE that uses a KEY column. To disable safe mode, toggle the option in Preferences -> SQL Editor and reconnect. 0.000 sec
詳細錯誤信息見附件截圖






評論(2)


零點溯靈
2025-02-16
-- 禁用安全模式
SET SQL_SAFE_UPDATES = 0;
-- 執(zhí)行你的 UPDATE 語句
UPDATE stu SET s_gender = '男' WHERE s_gender = '未知';
-- 恢復安全模式(可選)
SET SQL_SAFE_UPDATES = 1;
0.0000
0
0

CDA持證人阿濤哥
2024-10-28
CDA L1 mysql報錯Error Code: 1175. You are using safe update mode
http://www.3lll3.cn/discuss/post/details/63a4110de1840060d6346421
0.0000
0
0
推薦帖子
0條評論
1條評論
0條評論