You are viewing a plain text version of this content. The canonical link for it is here.
Posted to reviews@spark.apache.org by "cloud-fan (via GitHub)" <gi...@apache.org> on 2024/04/17 10:10:42 UTC
Re: [PR] [SPARK-47873][SQL] Write collated strings to Hive metastore using the regular string type [spark]
cloud-fan commented on code in PR #46083:
URL: https://github.com/apache/spark/pull/46083#discussion_r1568600521
##########
sql/api/src/main/scala/org/apache/spark/sql/types/DataType.scala:
##########
@@ -454,4 +454,29 @@ object DataType {
case (fromDataType, toDataType) => fromDataType == toDataType
}
}
+
+ /**
+ * Compares two types, ignoring nullability of ArrayType, MapType, StructType, ignoring case
+ * sensitivity of field names in StructType as well as differences in collation for String types.
+ */
+ def equalsIgnoreCaseNullabilityAndStringTypes(from: DataType, to: DataType): Boolean = {
Review Comment:
```suggestion
def equalsIgnoreCaseNullabilityAndCollation(from: DataType, to: DataType): Boolean = {
```
--
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: reviews-unsubscribe@spark.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org