You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@spark.apache.org by "Dongjoon Hyun (Jira)" <ji...@apache.org> on 2020/03/16 22:51:05 UTC
[jira] [Updated] (SPARK-26885) Remove yyyy/yyyy-[d]d format in
DataTimeUtils for stringToTimestamp and stringToDate
[ https://issues.apache.org/jira/browse/SPARK-26885?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Dongjoon Hyun updated SPARK-26885:
----------------------------------
Affects Version/s: (was: 3.0.0)
3.1.0
> Remove yyyy/yyyy-[d]d format in DataTimeUtils for stringToTimestamp and stringToDate
> ------------------------------------------------------------------------------------
>
> Key: SPARK-26885
> URL: https://issues.apache.org/jira/browse/SPARK-26885
> Project: Spark
> Issue Type: Improvement
> Components: SQL
> Affects Versions: 3.1.0
> Reporter: Darcy Shen
> Priority: Minor
>
> stringToTimestamp, stringToDate support yyyy, as a result:
> select year("1912") => 1912
> select month("1912") => 1
> select hour("1912") => 0
>
> In Presto or Hive,
> select year("1912") => null
> select month("1912") => null
> select hour("1912") => null
>
> It is not a good idea to support yyyy for a Date/DateTime.
>
--
This message was sent by Atlassian Jira
(v8.3.4#803005)
---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@spark.apache.org
For additional commands, e-mail: issues-help@spark.apache.org