-
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
plan, expression: support is null
in hash partition pruning (#17281)
#17308
plan, expression: support is null
in hash partition pruning (#17281)
#17308
Conversation
Signed-off-by: sre-bot <sre-bot@pingcap.com>
/run-all-tests |
LGTM |
/run-all-tests |
/rebuild |
PTAL @XuHuaiyu |
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
@qw4990,Thanks for you review. |
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
@zz-jason,Thanks for you review. |
/run-all-tests |
/run-all-tests |
cherry-pick #17281 to release-3.0
What problem does this PR solve?
Problem Summary:
SQL like
select * from t where a is null
will produce a full table scan plan in hash partition. For example:This SQL will produce following result:
What is changed and how it works?
Proposal: xxx
What's Changed:
During partition pruning, if a column is equal to
NULL
, all calculation relating to it will produce null result and set aNULL
flag.How it Works:
If pruning result with a
NULL
flag, it will be point top0
.Related changes
Check List
Tests
Side effects
Release note
is null
filter condition in hash partition pruning