dongjoon-hyun commented on a change in pull request #32764:
URL: https://github.com/apache/spark/pull/32764#discussion_r645137537
##########
File path:
sql/core/src/test/scala/org/apache/spark/sql/connector/DataSourceV2FunctionSuite.scala
##########
@@ -312,6 +344,27 @@ class DataSourceV2FunctionSuite extends
DatasourceV2SQLBase {
}
}
+ test("SPARK-35390: aggregate function w/ type coercion") {
+ import testImplicits._
+
+ withTable("t1", "t2") {
+ addFunction(Identifier.of(Array("ns"), "avg"), UnboundDecimalAverage)
+
+ (1 to 100).toDF().write.saveAsTable("testcat.ns.t1")
+ checkAnswer(sql(s"SELECT testcat.ns.avg(value) from testcat.ns.t1"),
Review comment:
And, ditto for line 358 and 362.
--
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]