[
https://issues.apache.org/jira/browse/SPARK-10681?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14876158#comment-14876158
]
Yin Huai commented on SPARK-10681:
----------------------------------
[~srowen] Yeah, originally that's also my thought. However, for our SQL
timestamp values, the unit is microsecond. {{getTime}} only give us
milliseconds and once we do {{* 1000}}, we lose the precision specified in the
String. For example, we have something like {{2015-01-01 23:00:00.123456}}.
Once we use {{getTime * 1000}}, we will get {{2015-01-01 23:00:00.123}}.
> DateTimeUtils needs a method to parse string to SQL's timestamp value
> ---------------------------------------------------------------------
>
> Key: SPARK-10681
> URL: https://issues.apache.org/jira/browse/SPARK-10681
> Project: Spark
> Issue Type: Improvement
> Components: SQL
> Reporter: Yin Huai
> Priority: Critical
>
> Right now, {{DateTimeUtils.stringToTime}} returns a java.util.Date whose
> getTime returns milliseconds. It will be great if we have a method to parse
> string directly to SQL's timestamp value (microseconds).
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]