You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@spark.apache.org by "Dean Chen (JIRA)" <ji...@apache.org> on 2016/07/18 04:59:20 UTC
[jira] [Closed] (SPARK-16597) DataFrame DateType is written as an
int(Days since epoch) by csv writer
[ https://issues.apache.org/jira/browse/SPARK-16597?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Dean Chen closed SPARK-16597.
-----------------------------
Resolution: Duplicate
> DataFrame DateType is written as an int(Days since epoch) by csv writer
> -----------------------------------------------------------------------
>
> Key: SPARK-16597
> URL: https://issues.apache.org/jira/browse/SPARK-16597
> Project: Spark
> Issue Type: Bug
> Components: SQL
> Affects Versions: 2.0.0
> Reporter: Dean Chen
> Labels: csv
>
> import java.sql.Date
> case class DateClass(date: java.sql.Date)
> val df = spark.createDataFrame(Seq(DateClass(new Date(1468774636000L))))
> df.write.csv("test.csv")
> file content is 16999, days since epoch instead of 7/17/16
--
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