cloud-fan commented on a change in pull request #31908:
URL: https://github.com/apache/spark/pull/31908#discussion_r638114867
##########
File path:
sql/catalyst/src/main/scala/org/apache/spark/sql/catalyst/plans/logical/basicLogicalOperators.scala
##########
@@ -844,6 +844,12 @@ case class Aggregate(
override protected def withNewChildInternal(newChild: LogicalPlan):
Aggregate =
copy(child = newChild)
+
+ // Whether this Aggregate operator is equally the Distinct operator.
+ private[sql] def isEquallyDistinct: Boolean = {
+ groupingExpressions.size == aggregateExpressions.size &&
+ groupingExpressions.zip(aggregateExpressions).forall(e =>
e._1.fastEquals(e._2))
Review comment:
I'd use `semanticEqual` here.
--
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.
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]