Skip to content

Commit

Permalink
remove decimal match in mathematics_numerical_coercion
Browse files Browse the repository at this point in the history
Signed-off-by: jayzhan211 <jayzhan211@gmail.com>
  • Loading branch information
jayzhan211 committed Dec 2, 2023
1 parent c6bcf8a commit 8dacdc9
Showing 1 changed file with 9 additions and 1 deletion.
10 changes: 9 additions & 1 deletion datafusion/expr/src/type_coercion/binary.rs
Original file line number Diff line number Diff line change
Expand Up @@ -616,7 +616,15 @@ fn mathematics_numerical_coercion(
(_, Dictionary(_, value_type)) => {
mathematics_numerical_coercion(lhs_type, value_type)
}
_ => comparison_binary_numeric_coercion(lhs_type, rhs_type),

// Dont match Decimal type
(lhs_type, rhs_type)
if (lhs_type.is_integer() || lhs_type.is_floating())
&& (rhs_type.is_integer() || rhs_type.is_floating()) =>
{
comparison_binary_numeric_coercion(lhs_type, rhs_type)
}
_ => None,
}
}

Expand Down

0 comments on commit 8dacdc9

Please sign in to comment.