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 2022/11/23 11:29:43 UTC

[GitHub] [spark] itholic commented on a diff in pull request #38769: [SPARK-41228][SQL] Rename & Improve error message for `COLUMN_NOT_IN_GROUP_BY_CLAUSE`.

itholic commented on code in PR #38769:
URL: https://github.com/apache/spark/pull/38769#discussion_r1030326286


##########
core/src/main/resources/error/error-classes.json:
##########
@@ -785,6 +779,13 @@
       "Malformed Protobuf messages are detected in message deserialization. Parse Mode: <failFastMode>. To process malformed protobuf message as null result, try setting the option 'mode' as 'PERMISSIVE'."
     ]
   },
+  "MISSING_AGGREGATION" : {
+    "message" : [
+      "The non-aggregating expression <expression> is based on columns which are not participating in the GROUP BY clause.",
+      "Add the columns or the expression to the GROUP BY, aggregate the expression, or use \"any_value(<expression>)\" if you do not care which of the values within a group is returned."

Review Comment:
   Yeah, it looks like the example below:
   
   ```
   [MISSING_AGGREGATION] The non-aggregating expression "c2" is based on columns which are not participating in the GROUP BY clause.
   Add the columns or the expression to the GROUP BY, aggregate the expression, or use "any_value("c2")" if you do not care which of the values within a group is returned.;
   ```
   
   Can we fix it to ``` `any_value("...")` ``` or something ?



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