You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@spark.apache.org by "Apache Spark (JIRA)" <ji...@apache.org> on 2016/05/18 10:14:13 UTC
[jira] [Assigned] (SPARK-15379) String to date and timestamp
conversion should return null on some invalid date string
[ https://issues.apache.org/jira/browse/SPARK-15379?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Apache Spark reassigned SPARK-15379:
------------------------------------
Assignee: Apache Spark
> String to date and timestamp conversion should return null on some invalid date string
> --------------------------------------------------------------------------------------
>
> Key: SPARK-15379
> URL: https://issues.apache.org/jira/browse/SPARK-15379
> Project: Spark
> Issue Type: Bug
> Components: SQL
> Affects Versions: 1.6.1, 2.0.0
> Reporter: Yang Wang
> Assignee: Apache Spark
> Priority: Minor
>
> spark.sql("select cast('2016-02-30 00:00:00' as date)") returns 2016-03-01, but spark.sql("select cast('2016-02-32 00:00:00' as date)") returns null. (See this notebook: https://databricks-prod-cloudfront.cloud.databricks.com/public/4027ec902e239c93eaaa8714f173bcfc/7973071962862063/3036006015533946/58107563000366/latest.html)
> I suppose all invalid dates should be returned as null.
> '2016-04-31', '2016-06-31', etc. also have the same issue.
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)
---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@spark.apache.org
For additional commands, e-mail: issues-help@spark.apache.org