-
Notifications
You must be signed in to change notification settings - Fork 28.9k
[SPARK-53318][SQL] Support the time type by make_timestamp_ltz() #52062
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
Conversation
Can we also update the examples with the new usage?
|
sql/core/src/test/resources/sql-tests/analyzer-results/timestamp-ltz.sql.out
Outdated
Show resolved
Hide resolved
Sure! Added two new expression examples. |
Thanks for making the updates. Just a couple last suggestions, can we also update the arguments to include
Also, I'm wondering if we should also apply similar changes to TryMakeTimestampLTZExpressionBuilder. I think it would make sense to also go in this PR since the change is so similar, but I'm not sure how it was done for the other TryMakeTimestamp ExpressionBuilders |
changes LGTM! |
@cloud-fan Please review. |
thanks, merging to master! |
What changes were proposed in this pull request?
In the PR, I propose to extend the
make_timestamp_ltz
function, and accept a date and time fields.Syntax
Arguments
date
: A date expression.time
: A time expression.Returns
A
TIMESTAMP_LTZ
.Examples
Why are the changes needed?
Users will be able to create a timestamp with local time zone by combining a time and a date.
Does this PR introduce any user-facing change?
Yes, this extends
make_timestamp_ltz
to accept additional kinds of inputs.How was this patch tested?
Added new e2e SQL tests in corresponding golden files.
Was this patch authored or co-authored using generative AI tooling?
No.