-
Notifications
You must be signed in to change notification settings - Fork 5.8k
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: do not build range for NullOuterVal in IndexLookUpJoin #8505
Conversation
/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
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.
@XuHuaiyu we should cherry pick this change to release-2.1 and release-2.0
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
…iyu/tidb into fix_inlj_range_from_handle
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
/run-all-tests |
/run-integration-ddl-test |
What problem does this PR solve?
fix #8499
Before this PR, the result of the following query is wrong.
What is changed and how it works?
When the innerPlan is a TableReader, the range of PKHanle will be built in buildTableReaderForIndexJoin,
and
NilDatum.GetInt64()
will return 0. Thus we read the row withPkHandle=0
twice, and get a duplicate result line.When the innerPlan is a IndexReader or IndexLookUpReader, we'll encode the NilDatum, thus no error happens.
Check List
Tests
Code changes
Side effects
none
Related changes
This change is