You are viewing a plain text version of this content. The canonical link for it is here.
Posted to reviews@spark.apache.org by cloud-fan <gi...@git.apache.org> on 2017/10/28 17:38:29 UTC
[GitHub] spark pull request #18113: [SPARK-20890][SQL] Added min and max typed aggreg...
Github user cloud-fan commented on a diff in the pull request:
https://github.com/apache/spark/pull/18113#discussion_r147559942
--- Diff: sql/core/src/main/scala/org/apache/spark/sql/execution/aggregate/typedaggregators.scala ---
@@ -26,43 +26,64 @@ import org.apache.spark.sql.expressions.Aggregator
// This file defines internal implementations for aggregators.
////////////////////////////////////////////////////////////////////////////////////////////////////
+class TypedSumDouble[IN](val f: IN => Double)
+ extends Aggregator[IN, java.lang.Double, java.lang.Double] {
+
+ override def zero: java.lang.Double = null
+ override def reduce(b: java.lang.Double, a: IN): java.lang.Double =
--- End diff --
OK let's follow the SQL semantic and deal with performance problem later. @setjet sorry for the late.
---
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org