Mysql 5.7,默认执行 update 语句时遇到错误提示:

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.

原因:

默认的安全策略,使得更新时,如果不依靠主键列进行查询时将被提示并失败。

解决方式:

SET SQL_SAFE_UPDATES = 0;

关闭掉该方式

修改如下:

SET SQL_SAFE_UPDATES = 0;

UPDATE `column` SET `column` = 新值 WHERE 非主键列条件;

SET SQL_SAFE_UPDATES = 1;

Mysql Update更新错误 Error Code:1175的更多相关文章

  1. MySQL Workbench update语句错误Error Code: 1175.

    rom:http://www.tuicool.com/articles/NJ3QRz MySQL update error: Error Code: 1175. You are using safe ...

  2. mysql 报错: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

    目录 #事故现场 #解决方法 #事故现场 mysql执行update操作报错: sql如下: update psmp.Users set name='Jack' where name='Lily'; ...

  3. MySql解除安全模式:Error Code: 1175. You are using safe update mode and you tried to update a table without a WHERE that uses a KEY column.

    在修改一条数据字段时报错: Error Code: 1175. You are using safe update mode and you tried to update a table witho ...

  4. mysql delete数据时报Error Code 1175

    我们在学校mysql的时候,在更新或者删除数据的时候,会遇到以下错误: Error Code: . You are using safe update mode and you tried to up ...

  5. 解决Mysql Workbench的Error Code: 1175错误

    错误: Error Code: 1175. You are using safe update mode and you tried to update a table without a WHERE ...

  6. mysql错误:Error Code: 1175. You are using safe update mode and you tried to update a table……

    今天遇到一个mysql错误:   Error Code: . You are using safe update mode and you tried to update a table withou ...

  7. MySql 执行 DELETE/UPDATE时,报 Error Code: 1175错误

    MySql 执行 DELETE FROM Table 时,报 Error Code: 1175. You are using safe update mode and you tried to upd ...

  8. Mysql 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

    今天用mysql workbench在更新数据的时候,出现了下面错误:15:52:39    update wp_posts set post_content = replace(post_conte ...

  9. Mysql update error: Error Code: 1175. You are using safe update mode and you tried to update a table

    Mysql update error: Error Code: 1175. You are using safe update mode and you tried to update a table ...

随机推荐

  1. [luogu3391] 【模板】文艺平衡树(fhq-treap反转区间)

    解题关键:无旋treap模板. #include<iostream> #include<cstdio> #include<cstring> #include< ...

  2. SQL Server 2008 R2 Express 不能启动

    今天,新安装了Sql Server 2008 R2 Express,准备部署相应系统,在完成了数据库还原,系统部署以后,从浏览器里输入系统网址,出现登录页面,登录时报错,无法连上数据库.在查找原因的过 ...

  3. CSS文本溢出处理

    1.超出层的高度和宽度时文本自动隐藏 overflow:hidden;text-overflow:ellipsis; 2.超出层的宽度时隐藏溢出的文本以...表示,Firefox不兼容,只隐藏溢出的文 ...

  4. launchpad, jira, github

    一.简介 http://segmentfault.com/q/1010000000165115

  5. javascript总结9:JavaScript三目运算符

    1 三元表达式: 表达式?结果1:结果2: 如果表达式结果为true,执行结果1,如果表达式结果为false,执行结果2. 可以理解为if else  的另外一种写法. 例: var m = 10; ...

  6. 编写高质量代码改善C#程序的157个建议——建议58:用抛出异常代替返回错误代码

    建议58:用抛出异常代替返回错误代码 CLR异常机制的优点: 正常控制流会被立即中止,无效值或状态不会在系统中继续传播. 提供了统一的处理错误的方法. 提供了在构造函数.操作符重载及属性中报告异常的遍 ...

  7. 编写高质量代码改善C#程序的157个建议——建议44:理解委托中的协变

    建议44:理解委托中的协变 委托中的泛型变量天然是部分支持协变的.为什么是“部分支持协变”?看下面示例: class Program { public delegate T GetEmployeeHa ...

  8. 编写高质量代码改善C#程序的157个建议——建议24:迭代器应该是只读的

    建议24:迭代器应该是只读的 如果注意观察会发现,FCL中的迭代器只有GetEnumerator方法,没有SetEnumerator方法,所有的集合类也没有一个可以写的迭代器属性.原因有二: 一:这违 ...

  9. vmware10中arch使用遇到的一些问题

    xfce4中安装中文输入法fcitx step 1  #pacman -S fcitx-im setp 2 在~/.xinitrc中添加如下内容: export LC_ALL=zh_CN.UTF-8e ...

  10. 策略(Strategy)模式

    /* * 环境(Context)角色:持有一个Strategy类的引用. * 抽象策略(Strategy)角色:这是一个抽象角色,通常由一个接口或抽象类实现.此角色给出所有的具体策略类所需的接口. * ...