You are viewing a plain text version of this content. The canonical link for it is here.
Posted to reviews@spark.apache.org by GitBox <gi...@apache.org> on 2021/04/08 14:03:50 UTC

[GitHub] [spark] AngersZhuuuu commented on a change in pull request #32089: [SPARK-34986][SQL] Make an error msg clearer when ordinal numbers in group-by refer to agg funcs

AngersZhuuuu commented on a change in pull request #32089:
URL: https://github.com/apache/spark/pull/32089#discussion_r609736958



##########
File path: sql/catalyst/src/main/scala/org/apache/spark/sql/errors/QueryCompilationErrors.scala
##########
@@ -268,6 +268,15 @@ private[spark] object QueryCompilationErrors {
       s"(valid range is [1, $size])", t.origin.line, t.origin.startPosition)
   }
 
+  def groupByPositionRefersToAggregateFunctionError(
+      index: Int,
+      expr: Expression,
+      t: TreeNode[_]): Throwable = {
+    new AnalysisException(s"GROUP BY expression in position $index is an aggregate function, " +

Review comment:
       > Nit: "aggregate function. Aggregate functions are not ..."
   
   Done




-- 
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:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org