[jira] [Assigned] (SPARK-37475) Add Scale Parameter to Floor and Ceil functions

2022-02-20 Thread Wenchen Fan (Jira)


 [ 
https://issues.apache.org/jira/browse/SPARK-37475?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Wenchen Fan reassigned SPARK-37475:
---

Assignee: Sathiya Kumar

> Add Scale Parameter to Floor and Ceil functions
> ---
>
> Key: SPARK-37475
> URL: https://issues.apache.org/jira/browse/SPARK-37475
> Project: Spark
>  Issue Type: New Feature
>  Components: SQL
>Affects Versions: 3.2.0
>Reporter: Sathiya Kumar
>Assignee: Sathiya Kumar
>Priority: Minor
> Fix For: 3.3.0
>
>
> This feature is proposed in the PR : 
> https://github.com/apache/spark/pull/34593
> Currently we support Decimal RoundingModes : HALF_UP (round) and HALF_EVEN 
> (bround). But we have use cases that needs RoundingMode.UP and 
> RoundingMode.DOWN.
> [https://stackoverflow.com/questions/34888419/round-down-double-in-spark/40476117]
> [https://stackoverflow.com/questions/54683066/is-there-a-rounddown-function-in-sql-as-there-is-in-excel]
> [https://stackoverflow.com/questions/48279641/oracle-sql-round-half]
>  
> Floor and Ceil functions helps to do this but it doesn't support the position 
> of the rounding. Adding scale parameter to the functions would help us 
> control the rounding positions. 
>  
> Snowflake supports `scale` parameter to `floor`/`ceil` :
> {code:java}
> FLOOR(  [,  ] ){code}
> REF:
> [https://docs.snowflake.com/en/sql-reference/functions/floor.html]
>  
>  
>  
>  



--
This message was sent by Atlassian Jira
(v8.20.1#820001)

-
To unsubscribe, e-mail: issues-unsubscr...@spark.apache.org
For additional commands, e-mail: issues-h...@spark.apache.org



[jira] [Assigned] (SPARK-37475) Add Scale Parameter to Floor and Ceil functions

2021-11-27 Thread Apache Spark (Jira)


 [ 
https://issues.apache.org/jira/browse/SPARK-37475?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Apache Spark reassigned SPARK-37475:


Assignee: (was: Apache Spark)

> Add Scale Parameter to Floor and Ceil functions
> ---
>
> Key: SPARK-37475
> URL: https://issues.apache.org/jira/browse/SPARK-37475
> Project: Spark
>  Issue Type: New Feature
>  Components: SQL
>Affects Versions: 3.2.0
>Reporter: Sathiya Kumar
>Priority: Minor
>
> Currently we support Decimal RoundingModes : HALF_UP (round) and HALF_EVEN 
> (bround). But we have use cases that needs RoundingMode.UP and 
> RoundingMode.DOWN.
> [https://stackoverflow.com/questions/34888419/round-down-double-in-spark/40476117]
> [https://stackoverflow.com/questions/54683066/is-there-a-rounddown-function-in-sql-as-there-is-in-excel]
> [https://stackoverflow.com/questions/48279641/oracle-sql-round-half]
>  
> Floor and Ceil functions helps to do this but it doesn't support the position 
> of the rounding. Adding scale parameter to the functions would help us 
> control the rounding positions. 
>  
> Snowflake supports `scale` parameter to `floor`/`ceil` :
> {code:java}
> FLOOR(  [,  ] ){code}
> REF:
> [https://docs.snowflake.com/en/sql-reference/functions/floor.html]
>  
>  
>  
>  



--
This message was sent by Atlassian Jira
(v8.20.1#820001)

-
To unsubscribe, e-mail: issues-unsubscr...@spark.apache.org
For additional commands, e-mail: issues-h...@spark.apache.org



[jira] [Assigned] (SPARK-37475) Add Scale Parameter to Floor and Ceil functions

2021-11-27 Thread Apache Spark (Jira)


 [ 
https://issues.apache.org/jira/browse/SPARK-37475?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Apache Spark reassigned SPARK-37475:


Assignee: Apache Spark

> Add Scale Parameter to Floor and Ceil functions
> ---
>
> Key: SPARK-37475
> URL: https://issues.apache.org/jira/browse/SPARK-37475
> Project: Spark
>  Issue Type: New Feature
>  Components: SQL
>Affects Versions: 3.2.0
>Reporter: Sathiya Kumar
>Assignee: Apache Spark
>Priority: Minor
>
> Currently we support Decimal RoundingModes : HALF_UP (round) and HALF_EVEN 
> (bround). But we have use cases that needs RoundingMode.UP and 
> RoundingMode.DOWN.
> [https://stackoverflow.com/questions/34888419/round-down-double-in-spark/40476117]
> [https://stackoverflow.com/questions/54683066/is-there-a-rounddown-function-in-sql-as-there-is-in-excel]
> [https://stackoverflow.com/questions/48279641/oracle-sql-round-half]
>  
> Floor and Ceil functions helps to do this but it doesn't support the position 
> of the rounding. Adding scale parameter to the functions would help us 
> control the rounding positions. 
>  
> Snowflake supports `scale` parameter to `floor`/`ceil` :
> {code:java}
> FLOOR(  [,  ] ){code}
> REF:
> [https://docs.snowflake.com/en/sql-reference/functions/floor.html]
>  
>  
>  
>  



--
This message was sent by Atlassian Jira
(v8.20.1#820001)

-
To unsubscribe, e-mail: issues-unsubscr...@spark.apache.org
For additional commands, e-mail: issues-h...@spark.apache.org