yaooqinn commented on a change in pull request #26681: [SPARK-30048][SQL]
Enable aggregates with interval type values for RelationalGroupedDataset
URL: https://github.com/apache/spark/pull/26681#discussion_r350758151
##########
File path:
sql/core/src/main/scala/org/apache/spark/sql/RelationalGroupedDataset.scala
##########
@@ -98,10 +98,10 @@ class RelationalGroupedDataset protected[sql](
// Make sure all specified columns are numeric.
colNames.map { colName =>
val namedExpr = df.resolve(colName)
- if (!namedExpr.dataType.isInstanceOf[NumericType]) {
+ if
(!TypeCollection.NumericAndInterval.acceptsType(namedExpr.dataType)) {
Review comment:
thanks for your suggestion. Please check 。
----------------------------------------------------------------
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]
With regards,
Apache Git Services
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]