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

Wenchen Fan resolved SPARK-27423.
---------------------------------
       Resolution: Fixed
    Fix Version/s: 3.0.0

Issue resolved by pull request 24332
[https://github.com/apache/spark/pull/24332]

> Cast DATE to/from TIMESTAMP according to SQL standard
> -----------------------------------------------------
>
>                 Key: SPARK-27423
>                 URL: https://issues.apache.org/jira/browse/SPARK-27423
>             Project: Spark
>          Issue Type: Improvement
>          Components: SQL
>    Affects Versions: 3.0.0
>            Reporter: Maxim Gekk
>            Assignee: Maxim Gekk
>            Priority: Minor
>             Fix For: 3.0.0
>
>
> According to SQL standard, DATE is union of (year, month, day). To convert it 
> to Spark's TIMESTAMP which is TIMESTAMP WITH TIME ZONE, the date should be 
> extended by time at midnight - (year, month, day, hour = 0, minute = 0, 
> seconds = 0). The former timestamp should be considered as a timestamp at the 
> session time zone, and transformed to microseconds since epoch in UTC.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

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

Reply via email to