mikhailnik-db commented on code in PR #51117:
URL: https://github.com/apache/spark/pull/51117#discussion_r2382774378
##########
sql/catalyst/src/main/scala/org/apache/spark/sql/catalyst/expressions/aggregate/collect.scala:
##########
@@ -317,21 +317,43 @@ private[aggregate] object CollectTopK {
case class ListAgg(
child: Expression,
delimiter: Expression = Literal(null),
- orderExpressions: Seq[SortOrder] = Nil,
+ orderChildExpressions: Seq[Expression] = Nil,
+ orderDirections: Seq[SortDirection] = Nil,
+ orderNullOrderings: Seq[NullOrdering] = Nil,
+ orderSameOrderExpressions: Seq[Seq[Expression]] = Nil,
Review Comment:
I think we don't need those 2
* ~~`orderNullOrderings` does not matter, because nulls are treated as an
empty string/byte array~~
* ofc nulls ordering is important if it's not the same expression we
aggregate 😅
* `orderSameOrderExpressions` does not matter because the row comparator
`InterpretedOrdering` does not use it.
* Moreover, I checked all usages of `SortOrder.sameOrderExpressions` and
it's used only in `SortMergeJoinExec`.
--
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]