Github user maropu commented on a diff in the pull request: https://github.com/apache/spark/pull/22419#discussion_r219858062 --- Diff: sql/core/src/main/scala/org/apache/spark/sql/functions.scala --- @@ -2214,6 +2214,26 @@ object functions { */ def radians(columnName: String): Column = radians(Column(columnName)) + /** + * Returns the value of the column `e` truncated to 0 places. + * + * @group math_funcs + * @since 2.4.0 + */ + def truncate(e: Column): Column = truncate(e, 0) + + /** + * Returns the value of column `e` truncated to the unit specified by the scale. + * If scale is omitted, then the value of column `e` is truncated to 0 places. + * Scale can be negative to truncate (make zero) scale digits left of the decimal point. + * + * @group math_funcs + * @since 2.4.0 --- End diff -- ditto
--- --------------------------------------------------------------------- To unsubscribe, e-mail: reviews-unsubscr...@spark.apache.org For additional commands, e-mail: reviews-h...@spark.apache.org