You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@spark.apache.org by "Maxim Gekk (JIRA)" <ji...@apache.org> on 2019/04/09 21:59:00 UTC
[jira] [Created] (SPARK-27423) Cast DATE to/from TIMESTAMP
according to SQL standard
Maxim Gekk created SPARK-27423:
----------------------------------
Summary: 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
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-unsubscribe@spark.apache.org
For additional commands, e-mail: issues-help@spark.apache.org