免费注册 查看新帖 |

Chinaunix

  平台 论坛 博客 文库
最近访问板块 发新帖
查看: 3245 | 回复: 4
打印 上一主题 下一主题

mysql不断报错 [复制链接]

论坛徽章:
0
跳转到指定楼层
1 [收藏(0)] [报告]
发表于 2010-08-10 15:07 |只看该作者 |倒序浏览
mysql错误日志不断的报错
100810 15:06:17 [Warning] Statement may not be safe to log in statement format. Statement: update cdb_roup set isclose=1 where tid='2030596'  limit 1
100810 15:06:17 [Warning] Statement may not be safe to log in statement format. Statement: update cdb_roup set isclose=1 where tid='1221957'  limit 1
100810 15:06:17 [Warning] Statement may not be safe to log in statement format. Statement: update cdb_roup set isclose=1 where tid='2340202'  limit 1
100810 15:06:17 [Warning] Statement may not be safe to log in statement format. Statement: update cdb_roup set isclose=1 where tid='2113223'  limit 1
100810 15:06:17 [Warning] Statement may not be safe to log in statement format. Statement: update cdb_roup set isclose=1 where tid='1465090'  limit 1
100810 15:06:17 [Warning] Statement may not be safe to log in statement format. Statement: update cdb_roup set isclose=1 where tid='2375480'  limit 1
100810 15:06:17 [Warning] Statement may not be safe to log in statement format. Statement: update cdb_roup set isclose=1 where tid='913938'  limit 1
100810 15:06:17 [Warning] Statement may not be safe to log in statement format. Statement: update cdb_roup set isclose=1 where tid='1190391'  limit 1
100810 15:06:17 [Warning] Statement may not be safe to log in statement format. Statement: update cdb_roup set isclose=1 where tid='1115575'  limit 1
100810 15:06:17 [Warning] Statement may not be safe to log in statement format. Statement: update cdb_roup set isclose=1 where tid='2377993'  limit 1
100810 15:06:18 [Warning] Statement may not be safe to log in statement format. Statement: update cdb_roup set isclose=1 where tid='2118499'  limit 1
100810 15:06:18 [Warning] Statement may not be safe to log in statement format. Statement: update cdb_roup set isclose=1 where tid='1353972'  limit 1
100810 15:06:18 [Warning] Statement may not be safe to log in statement format. Statement: update cdb_roup set isclose=1 where tid='1494045'  limit 1
100810 15:06:18 [Warning] Statement may not be safe to log in statement format. Statement: update cdb_roup set isclose=1 where tid='2113775'  limit 1
100810 15:06:18 [Warning] Statement may not be safe to log in statement format. Statement: update cdb_roup set isclose=1 where tid='681937'  limit 1
100810 15:06:18 [Warning] Statement may not be safe to log in statement format. Statement: update cdb_roup set isclose=1 where tid='91568'  limit 1
100810 15:06:18 [Warning] Statement may not be safe to log in statement format. Statement: update cdb_roup set isclose=1 where tid='908609'  limit 1
100810 15:06:19 [Warning] Statement may not be safe to log in statement format. Statement: update cdb_roup set isclose=1 where tid='


请教如何解决

论坛徽章:
0
2 [报告]
发表于 2010-12-10 21:16 |只看该作者
如果不违反业务逻辑,把语句里面的 limit 1去掉看看。

论坛徽章:
0
3 [报告]
发表于 2010-12-10 21:21 |只看该作者
如果不违反业务逻辑,把语句里面的 limit 1去掉看看。

论坛徽章:
0
4 [报告]
发表于 2010-12-11 22:07 |只看该作者
回复 1# wangc0727


    这个是binlog的格式是statement引起的. statement对某些sql是不安全的,比如有自动生成uuid的语句,再比如lz这个语句可能是limit 1可能会由于 master slave的某些原因导致更新的不是同一个语句 (比如mysql的版本不一致而造成第一条语句不同). 将binlog格式改成 row或者 mixed:

http://dev.mysql.com/doc/refman/5.1/en/binary-log-setting.html

论坛徽章:
0
5 [报告]
发表于 2013-02-05 21:25 |只看该作者
回复 4# chylli


    楼上的回答是正确的。
您需要登录后才可以回帖 登录 | 注册

本版积分规则 发表回复

  

北京盛拓优讯信息技术有限公司. 版权所有 京ICP备16024965号-6 北京市公安局海淀分局网监中心备案编号:11010802020122 niuxiaotong@pcpop.com 17352615567
未成年举报专区
中国互联网协会会员  联系我们:huangweiwei@itpub.net
感谢所有关心和支持过ChinaUnix的朋友们 转载本站内容请注明原作者名及出处

清除 Cookies - ChinaUnix - Archiver - WAP - TOP