-
Notifications
You must be signed in to change notification settings - Fork 1.3k
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
Consider timezones with UTC
and +00:00
to be the same
#10960
Conversation
I responded on #10957 (comment) |
+1 on including type coercion logic for "UTC" and "+00:00" and leaving the signature of NowFunc unchanged. This would fix the error described in #10957 more generally without introducing any breaking changes |
4c43bd4
to
e1cfb48
Compare
...perhaps someone can help me out on this. I still haven't found a way to create a timestamp with timezone in order to create a proper sqllogictest. |
There are some examples here: #10602 You can also use arrow_cast (there are some examples here https://datafusion.apache.org/user-guide/sql/scalar_functions.html#arrow-cast) |
I think this should be fixed now. I added some sqllogictest as well to validate the new behavior - thanks @alamb for the pointer on |
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.
Thank you @marvinlanhenke and @samuelcolvin -- this looks good to me
cc @waitingkuo
I added some additional comments and merged up from main. @erratic-pattern if you have time, it would be great if you could review this PR as well |
UTC
and +00:00
offsets are the same
UTC
and +00:00
offsets are the sameUTC
and +00:00
offsets are the same
UTC
and +00:00
offsets are the sameUTC
and +00:00
to be the same
Thanks everyone! |
* feat: add temporal_coercion check * fix: add return stmt * chore: add slts * fix: remove println * Update datafusion/expr/src/type_coercion/binary.rs --------- Co-authored-by: Andrew Lamb <[email protected]>
* feat: add temporal_coercion check * fix: add return stmt * chore: add slts * fix: remove println * Update datafusion/expr/src/type_coercion/binary.rs --------- Co-authored-by: Andrew Lamb <[email protected]>
* feat: add temporal_coercion check * fix: add return stmt * chore: add slts * fix: remove println * Update datafusion/expr/src/type_coercion/binary.rs --------- Co-authored-by: Andrew Lamb <[email protected]>
* feat: add temporal_coercion check * fix: add return stmt * chore: add slts * fix: remove println * Update datafusion/expr/src/type_coercion/binary.rs --------- Co-authored-by: Andrew Lamb <[email protected]>
* feat: add temporal_coercion check * fix: add return stmt * chore: add slts * fix: remove println * Update datafusion/expr/src/type_coercion/binary.rs --------- Co-authored-by: Andrew Lamb <[email protected]>
Which issue does this PR close?
Closes #10957.
Rationale for this change
Timezone was specified as "+00:00" instead of "UTC". This caused a missmatch in
temporal_coercion
.What changes are included in this PR?
Are these changes tested?
Are there any user-facing changes?