e-dard commented on a change in pull request #1196:
URL: https://github.com/apache/arrow-rs/pull/1196#discussion_r787601001
##########
File path: arrow/src/compute/kernels/cast.rs
##########
@@ -1111,6 +1118,17 @@ pub fn cast_with_options(
}
}
}
+ (Duration(_), Int64) => cast_array_data::<Int64Type>(array,
to_type.clone()),
+ (Interval(from_type), Int64) => match from_type {
+ IntervalUnit::YearMonth => {
+ cast_numeric_arrays::<IntervalYearMonthType, Int64Type>(array)
+ }
+ IntervalUnit::DayTime => cast_array_data::<Int64Type>(array,
to_type.clone()),
Review comment:
In terms of the `DayTime` value I was thinking along the lines of this
comment https://github.com/apache/arrow-rs/issues/685#issuecomment-897877620
(emit it as it is and then the user can optionally do another operation on it
if they need to).
--
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]