-
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
ranger: fix the range construction behavior when the column's type is YEAR
(#23559)
#24018
Conversation
Signed-off-by: ti-srebot <[email protected]>
[REVIEW NOTIFICATION] This pull request has not been approved. To complete the pull request process, please ask the reviewers in the list to review by filling The full list of commands accepted by this bot can be found here. Reviewer can indicate their review by writing |
/run-all-tests |
@wjhuang2016 you're already a collaborator in bot's repo. |
@wjhuang2016 please take a look at the failed CI. |
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.
Please resolve conflicts @wjhuang2016
Please resolve conflicts @wjhuang2016 🤣 ... too many test cases false-fail everyday in 5.0 |
Not critical enough to be merged into 5.0. |
cherry-pick #23559 to release-5.0
You can switch your code base to this Pull Request by using git-extras:
# In tidb repo: git pr https://github.com/pingcap/tidb/pull/24018
After apply modifications, you can push your change to this PR via:
Signed-off-by: wjhuang2016 [email protected]
What problem does this PR solve?
Issue Number: close #23508
Problem Summary:
The type of year should be int, not double.
What is changed and how it works?
Use ConvertToMysqlYear() to adjust the year constant, and handle some corner cases.
Related changes
Check List
Tests
Unit test
Manual test (add detailed scripts or steps below)
Start a tidb cluster.
CREATE TABLE
PK_S_MULTI_42_2
(COL1
year(4) NOT NULL,COL2
year(4) NOT NULL,COL3
year(4) DEFAULT NULL, PRIMARY KEY (COL1
,COL2
) clustered);mysql> select * from PK_S_MULTI_42_2 where col2 between 2154 and 2154 AND col3 > 2153;
Empty set (0.00 sec)
Side effects
Release note