You are viewing a plain text version of this content. The canonical link for it is here.
Posted to reviews@spark.apache.org by GitBox <gi...@apache.org> on 2022/03/21 09:11:39 UTC

[GitHub] [spark] sathiyapk commented on a change in pull request #35913: [SPARK-38604][SQL] Keep ceil and floor with only a single argument the same as before

sathiyapk commented on a change in pull request #35913:
URL: https://github.com/apache/spark/pull/35913#discussion_r830884817



##########
File path: sql/core/src/main/scala/org/apache/spark/sql/functions.scala
##########
@@ -1783,7 +1783,9 @@ object functions {
    * @group math_funcs
    * @since 1.4.0
    */
-  def ceil(e: Column): Column = ceil(e, lit(0))
+  def ceil(e: Column): Column = withExpr {
+    UnresolvedFunction(Seq("ceil"), Seq(e.expr), isDistinct = false)

Review comment:
       I think we can call `ceil(input)`/`floor(input)` if `scale = 0`, but we need the test case to validate the modifications.   @awdavidson @revans2 Could you please provide us the test case to be sure ? thanks.




-- 
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.

To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org