Github user cloud-fan commented on a diff in the pull request:
https://github.com/apache/spark/pull/19692#discussion_r150697438
--- Diff:
sql/catalyst/src/main/scala/org/apache/spark/sql/catalyst/analysis/TypeCoercion.scala
---
@@ -137,6 +137,8 @@ object TypeCoercion {
case (DateType, TimestampType) => Some(StringType)
case (StringType, NullType) => Some(StringType)
case (NullType, StringType) => Some(StringType)
+ case (n: NumericType, s: StringType) => Some(DoubleType)
+ case (s: StringType, n: NumericType) => Some(DoubleType)
--- End diff --
How about we cast both sides to double for string and decimal combo? We
can't find a proper decimal precision anyway.
---
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]