File tree Expand file tree Collapse file tree 1 file changed +5
-0
lines changed
datafusion/physical-expr/src/coercion_rule Expand file tree Collapse file tree 1 file changed +5
-0
lines changed Original file line number Diff line number Diff line change @@ -585,6 +585,7 @@ pub fn interval_coercion(
585585 rhs_type : & DataType ,
586586) -> Option < DataType > {
587587 use arrow:: datatypes:: DataType :: * ;
588+ use arrow:: datatypes:: IntervalUnit :: * ;
588589
589590 // these are ordered from most informative to least informative so
590591 // that the coercion removes the least amount of information
@@ -605,6 +606,10 @@ pub fn interval_coercion(
605606 _ => None ,
606607 } ,
607608 Operator :: Multiply => match ( lhs_type, rhs_type) {
609+ ( Float64 , Interval ( _) )
610+ | ( Interval ( _) , Float64 )
611+ | ( Float32 , Interval ( _) )
612+ | ( Interval ( _) , Float32 ) => Some ( Interval ( MonthDayNano ) ) ,
608613 ( Utf8 , Interval ( itype) )
609614 | ( Interval ( itype) , Utf8 )
610615 | ( Int64 , Interval ( itype) )
You can’t perform that action at this time.
0 commit comments