-
Notifications
You must be signed in to change notification settings - Fork 5.9k
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
executor: fix last_insert_id in auto_random mode (#15145) #15149
Conversation
Signed-off-by: sre-bot <sre-bot@pingcap.com>
/run-all-tests |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM, good job.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
/merge |
Sorry @djshow832, you don't have permission to trigger auto merge event on this branch. |
/run-all-tests |
/merge |
/run-all-tests |
cherry-pick #15145 to release-3.1
Conflicting files:
insert_common.go
insert_test.go
What problem does this PR solve?
Fix #15140.
What is changed and how it works?
NO_AUTO_VALUE_ON_ZERO
and fill auto value with inserting 0.Check List
Tests
Code changes
N/A
Side effects
N/A
Related changes
Release note
last_insert_id
is wrong when inserting withauto_random
; Inserting 0 withauto_random
column is not replaced with an allocated value.