You are viewing a plain text version of this content. The canonical link for it is here.
Posted to github@arrow.apache.org by "viirya (via GitHub)" <gi...@apache.org> on 2023/06/12 23:58:22 UTC

[GitHub] [arrow-datafusion] viirya commented on a diff in pull request #6654: fix: 'datatrunc' return inconsistent type

viirya commented on code in PR #6654:
URL: https://github.com/apache/arrow-datafusion/pull/6654#discussion_r1227352646


##########
datafusion/physical-expr/src/datetime_expressions.rs:
##########
@@ -294,16 +294,24 @@ pub fn date_trunc(args: &[ColumnarValue]) -> Result<ColumnarValue> {
                 }
                 "second" => {
                     // trunc to second
-                    let mill = ScalarValue::TimestampNanosecond(

Review Comment:
   And the `signature` of `DateTrunc` should be updated, I think. Currently the second argument is only `Timestamp(Nanosecond, None)`. But I guess that this change wants to make output type as same as input type. So you probably want to add more input types to `signature`.



-- 
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: github-unsubscribe@arrow.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org