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

Remove "session" from "set transaction" statement #263

Closed
bgrainger opened this issue May 13, 2017 · 2 comments
Closed

Remove "session" from "set transaction" statement #263

bgrainger opened this issue May 13, 2017 · 2 comments
Labels

Comments

@bgrainger
Copy link
Member

The BeginTransaction method executes a set session transaction isolation level statement (here).

As per 14.3.6 SET TRANSACTION Syntax:

  • With the SESSION keyword, the statement applies to all subsequent transactions performed within the current session.
  • Without any SESSION or GLOBAL keyword, the statement applies to the next (not started) transaction performed within the current session. Subsequent transactions revert to using the SESSION isolation level.

The use of the SESSION keyword is inappropriate here, as we only want to change the isolation level for the immediate next transaction.

(See also MySQL bug 86263.)

@bgrainger
Copy link
Member Author

Didn't add a test, since bug 53341 means that there's no way to read the current transaction's isolation level. (We could test that the session's isolation level hasn't changed, but a more useful test would be ensuring that the desired isolation level was actually applied.)

bgrainger added a commit that referenced this issue May 16, 2017
@bgrainger
Copy link
Member Author

Fixed in 0.19.5.

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

No branches or pull requests

1 participant