cloud-fan commented on code in PR #48585:
URL: https://github.com/apache/spark/pull/48585#discussion_r1810842204
##########
sql/catalyst/src/main/scala/org/apache/spark/sql/catalyst/analysis/AnsiTypeCoercion.scala:
##########
@@ -148,6 +149,10 @@ object AnsiTypeCoercion extends TypeCoercionBase {
// interval type the string should be promoted as. There are many
possible interval
// types, such as year interval, month interval, day interval, hour
interval, etc.
case (_: StringType, _: AnsiIntervalType) => None
+ // [SPARK-50060] If a binary operation contains at least one collated
string types, we can't
+ // decide which collation the result should have.
+ case (d1: StringType, d2: StringType) if
SchemaUtils.hasNonUTF8BinaryCollation(d1) ||
Review Comment:
This makes me think that maybe we should not put string collation type
coercion in an individual rule, as other type coercion rules must be aware of
string collation as well. Shall we just make each type coercion rule collation
aware?
--
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]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]