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

ddl, lightning: support detecting duplicate keys in different batch #40701

Merged
merged 6 commits into from
Jan 19, 2023
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
fix linter
  • Loading branch information
tangenta committed Jan 18, 2023
commit df47106a894d7833bb40cc06c67e639cae92f24c
6 changes: 3 additions & 3 deletions ddl/index.go
Original file line number Diff line number Diff line change
Expand Up @@ -892,9 +892,9 @@ func convertToKeyExistsErr(originErr error, idxInfo *model.IndexInfo, tblInfo *m
if len(tErr.Args()) != 2 {
return originErr
}
key, kIsByte := tErr.Args()[0].([]byte)
value, vIsByte := tErr.Args()[1].([]byte)
if !kIsByte || !vIsByte {
key, keyIsByte := tErr.Args()[0].([]byte)
value, valIsByte := tErr.Args()[1].([]byte)
if !keyIsByte || !valIsByte {
return originErr
}
return genKeyExistsErr(key, value, idxInfo, tblInfo)
Expand Down