maropu commented on a change in pull request #29673:
URL: https://github.com/apache/spark/pull/29673#discussion_r486232651



##########
File path: sql/core/src/test/scala/org/apache/spark/sql/DataFrameSuite.scala
##########
@@ -2555,6 +2555,16 @@ class DataFrameSuite extends QueryTest
     val df = Seq(0.0 -> -0.0).toDF("pos", "neg")
     checkAnswer(df.select($"pos" > $"neg"), Row(false))
   }
+
+  test("SPARK-32816: aggregating multiple distinct DECIMAL columns") {
+    checkAnswer(
+      sql(
+        s"""
+           |SELECT AVG(DISTINCT decimal_col), SUM(DISTINCT decimal_col)
+           |  FROM VALUES (CAST(1 AS DECIMAL(9, 0))) t(decimal_col)
+        """.stripMargin),
+      Row(1, 1))

Review comment:
       nit: the test `group-by.sql` looks enough for this issue, so could you 
remove this?




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

Reply via email to