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

Wenchen Fan reassigned SPARK-33794:
-----------------------------------

    Assignee: Chongguang LIU

> next_day function should throw runtime exception when receiving invalid input 
> under ANSI mode
> ---------------------------------------------------------------------------------------------
>
>                 Key: SPARK-33794
>                 URL: https://issues.apache.org/jira/browse/SPARK-33794
>             Project: Spark
>          Issue Type: Sub-task
>          Components: SQL
>    Affects Versions: 3.0.0
>            Reporter: Chongguang LIU
>            Assignee: Chongguang LIU
>            Priority: Major
>
> Hello all,
> According to [ANSI 
> compliance|https://spark.apache.org/docs/3.0.0/sql-ref-ansi-compliance.html#ansi-compliance],
>  the [next_day 
> function|https://github.com/apache/spark/blob/master/sql/core/src/main/scala/org/apache/spark/sql/functions.scala#L3095]
>  should throw an runtime exception when receiving invalid value for 
> dayOfWeek, exemple receiving "xx" instead of "SUNDAY".
>  
> A similar improvement has been done on the element_at function: 
> https://issues.apache.org/jira/browse/SPARK-33386
>  
> If you agree with this proposition, i can submit a pull request with 
> necessary change.
>  
> Kind regardes,
>  



--
This message was sent by Atlassian Jira
(v8.3.4#803005)

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

Reply via email to