Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

不支持begin方式开启事务 #591

Closed
wo23wo32 opened this issue Jan 30, 2018 · 1 comment
Closed

不支持begin方式开启事务 #591

wo23wo32 opened this issue Jan 30, 2018 · 1 comment

Comments

@wo23wo32
Copy link

因为采用dbproxy中间件,由dbproxy维持到mysql的connection。为了复用连接,不支持autocommit=0的方式开启事务,只能显式执行begin来开启事务。
但是sharding-jdbc没有实现begin或start transaction的MySQLParser。

Which version of Sharding-Jdbc do you using?(您使用的Sharding-Jdbc版本为?)

1.5.4.1

Expected behavior (您预期的结果是)

可以正常执行statement.executeUpdate("BEGIN");

Actual behavior (实际运行的结果是)

报异常com.dangdang.ddframe.rdb.sharding.parsing.parser.exception.SQLParsingUnsupportedException: Not supported token 'BEGIN'.

Steps to reproduce the behavior (可重现问题的操作步骤)

执行statement.executeUpdate("BEGIN");

@terrymanu
Copy link
Member

duplicate with #600

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants