Jefffrey commented on code in PR #19640:
URL: https://github.com/apache/datafusion/pull/19640#discussion_r2661149997
##########
datafusion/functions/src/datetime/date_trunc.rs:
##########
Review Comment:
We'll need to consider LargeUtf8 here now for completeness
##########
datafusion/functions/src/datetime/date_trunc.rs:
##########
@@ -256,6 +249,22 @@ impl ScalarUDFImpl for DateTruncFunc {
let granularity = DateTruncGranularity::from_str(&granularity_str)?;
+ // Check upfront if granularity is valid for Time types
+ let is_time_type = match array {
Review Comment:
ColumnarValue has a data_type method so we don't need to destructure it
https://docs.rs/datafusion/latest/datafusion/logical_expr/enum.ColumnarValue.html#method.data_type
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]