10110346 commented on a change in pull request #23304: [SPARK-26353][SQL]Add 
typed aggregate functions: max&&min
URL: https://github.com/apache/spark/pull/23304#discussion_r247726185
 
 

 ##########
 File path: 
sql/core/src/main/java/org/apache/spark/sql/expressions/javalang/typed.java
 ##########
 @@ -74,4 +71,40 @@
   public static <T> TypedColumn<T, Long> sumLong(MapFunction<T, Long> f) {
     return new TypedSumLong<T>(f).toColumnJava();
   }
+
+  /**
+   * Min aggregate function for floating point (double) type.
+   *
+   * @since 3.0.0
+   */
+  public static <T> TypedColumn<T, Double> min(MapFunction<T, Double> f) {
+    return new JavaTypedMinDouble<T>(f).toColumn();
+  }
+
+  /**
+   * Min aggregate function for integral (long, i.e. 64 bit integer) type.
+   *
+   * @since 3.0.0
+   */
+  public static <T> TypedColumn<T, Long> minLong(MapFunction<T, Long> f) {
+    return new JavaTypedMinLong<T>(f).toColumn();
+  }
+
+  /**
+   * Min aggregate function for floating point (double) type.
 
 Review comment:
   Ok,thanks

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on 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]

Reply via email to