MySQL:未知的系统变量'tx_read_only' [英] MySQL: Unknown system variable 'tx_read_only'

查看:532
本文介绍了MySQL:未知的系统变量'tx_read_only'的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在基于Java Swing的应用程序+ Hibernate + Mysql + Spring. 当我测试CRUD操作时,读取没有问题,但是在插入语句中,系统显示以下消息:

I'm working on a Java Swing-based application+ Hibernate+Mysql+Spring. When I test CRUD operations, I don't have problems with read, but in insert statements system shows the message:

Unknown system variable `tx_read_only`

我拥有MySQl的最新版本

I have the last version of MySQl

  • 休眠4
  • Java注释

您能告诉我现在要解决的问题吗?

Can you tell me which is the problem to solve now?

推荐答案

只是向黑暗中扔石头,但是一种可能是:

Just throwing rocks to the darkness, but one possibility could be:

  • 变量 tx_read_only 是在MySQL 5.6.5中引入的.
  • 可能MySQL版本早于该版本,但是Connector/J仍然尝试使用新变量.
  • 发行说明,Connector/J 5.1.23中对此变量提供了支持.
  • Variable tx_read_only was introduced in MySQL 5.6.5.
  • Probably MySQL version is older than that, but Connector/J tries to use new variable anyway.
  • According release notes, support for this variable came in Connector/J 5.1.23.

==>也许早于5.1.23的版本可以工作,或者这是比该版本更新的错误.

==> maybe version older than 5.1.23 will work, or this is the bug that is fixed in version newer than that.

这篇关于MySQL:未知的系统变量'tx_read_only'的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆