Shekharrajak commented on code in PR #2994:
URL: https://github.com/apache/datafusion-comet/pull/2994#discussion_r3008087673


##########
spark/src/main/scala/org/apache/spark/sql/comet/operators.scala:
##########
@@ -1368,11 +1371,15 @@ trait CometBaseAggregate {
       return None
     }
 
-    if (groupingExpressions.exists(expr =>
-        expr.dataType match {
-          case _: MapType => true
-          case _ => false
-        })) {
+    def containsMapType(dt: DataType): Boolean = dt match {
+      case _: MapType => true
+      case a: ArrayType => containsMapType(a.elementType)

Review Comment:
   some queries have array of maps - recursively checking for MapType within 
ArrayType and StructType.
   This ensures we correctly fall back to Spark for any grouping expression
   that contains a MapType at any nesting level.



-- 
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]

Reply via email to