-
Notifications
You must be signed in to change notification settings - Fork 3.4k
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
[Bug](function) Fix function for cast string as date/datetime #35637
Conversation
Thank you for your contribution to Apache Doris. Since 2024-03-18, the Document has been moved to doris-website. |
run buildall |
TPC-H: Total hot run time: 42114 ms
|
TPC-DS: Total hot run time: 171655 ms
|
ClickBench: Total hot run time: 30.69 s
|
4a9094d
to
f9f7db0
Compare
run buildall |
f9f7db0
to
2434659
Compare
run buildall |
run performance |
run p0 |
TPC-H: Total hot run time: 40485 ms
|
TPC-DS: Total hot run time: 169286 ms
|
ClickBench: Total hot run time: 30.32 s
|
run p0 |
what's the behaviour in other db system? |
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.
We need a strong basis to prove that this change is necessary.
2434659
to
e5d6e1b
Compare
run buildall |
TPC-H: Total hot run time: 40949 ms
|
TPC-DS: Total hot run time: 173565 ms
|
ClickBench: Total hot run time: 31.03 s
|
run p0 |
1 similar comment
run p0 |
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
|
PR approved by at least one committer and no changes requested. |
PR approved by anyone and no changes requested. |
run Need_2_Approval |
…#35637) Issue Number: close apache#35635 <!--Describe your changes.--> Cast rules:Consistent with mysql. String:Date The first part is 1-digit x: 000x-month-day The first part is 2-digit xy: 20xy-month-day / 19xy-month-day The first part is 3-digit xyz: 20xy-0z-day / 19xy-0z-day The first part is 4-digit xyzw: xyzw-month-day
## Proposed changes Issue Number: close #35635 <!--Describe your changes.--> Cast rules:Consistent with mysql. String:Date The first part is 1-digit x: 000x-month-day The first part is 2-digit xy: 20xy-month-day / 19xy-month-day The first part is 3-digit xyz: 20xy-0z-day / 19xy-0z-day The first part is 4-digit xyzw: xyzw-month-day
#37891) ## Proposed changes Issue Number: close #35635 cherry-pick #35637 from master to branch-2.1 <!--Describe your changes.--> Cast rules:Consistent with mysql. String:Date The first part is 1-digit x: 000x-month-day The first part is 2-digit xy: 20xy-month-day / 19xy-month-day The first part is 3-digit xyz: 20xy-0z-day / 19xy-0z-day The first part is 4-digit xyzw: xyzw-month-day ## Proposed changes Issue Number: close #xxx <!--Describe your changes.-->
…#35637) (apache#35931) cherry-pick apache#35637 from master to branch-2.0
### What problem does this PR solve? Issue Number: close #xxx Related PR: #35637 Problem Summary: When cast("201-01-01" as datetimev2(0)), The result is "2020-01-01" but it is wrong. It should be result in "0201-01-01". 201 would be regarded as 20xy-0z as related pr show, it was a bug. But actually it should not have this trasformation and result in
### What problem does this PR solve? Issue Number: close #xxx Related PR: #35637 Problem Summary: When cast("201-01-01" as datetimev2(0)), The result is "2020-01-01" but it is wrong. It should be result in "0201-01-01". 201 would be regarded as 20xy-0z as related pr show, it was a bug. But actually it should not have this trasformation and result in
Issue Number: close #xxx Related PR: apache#35637 Problem Summary: When cast("201-01-01" as datetimev2(0)), The result is "2020-01-01" but it is wrong. It should be result in "0201-01-01". 201 would be regarded as 20xy-0z as related pr show, it was a bug. But actually it should not have this trasformation and result in
Issue Number: close #xxx Related PR: apache#35637 Problem Summary: When cast("201-01-01" as datetimev2(0)), The result is "2020-01-01" but it is wrong. It should be result in "0201-01-01". 201 would be regarded as 20xy-0z as related pr show, it was a bug. But actually it should not have this trasformation and result in
Issue Number: close #xxx Related PR: apache#35637 Problem Summary: When cast("201-01-01" as datetimev2(0)), The result is "2020-01-01" but it is wrong. It should be result in "0201-01-01". 201 would be regarded as 20xy-0z as related pr show, it was a bug. But actually it should not have this trasformation and result in
pick: #46065 Related PR: #35637 Problem Summary: When cast("201-01-01" as datetimev2(0)), The result is "2020-01-01" but it is wrong. It should be result in "0201-01-01". 201 would be regarded as 20xy-0z as related pr show, it was a bug. But actually it should not have this trasformation and result in
Proposed changes
Issue Number: close #35635
Cast rules:Consistent with mysql.
String:Date
The first part is 1-digit x: 000x-month-day
The first part is 2-digit xy: 20xy-month-day / 19xy-month-day
The first part is 3-digit xyz: 20xy-0z-day / 19xy-0z-day
The first part is 4-digit xyzw: xyzw-month-day