How do I convert column of unix epoch to Date in Apache spark DataFrame using Java?
<p>I have a json data file which contain one property [creationDate] which is unix epoc in "long" number type. The Apache Spark DataFrame schema look like below:</p>

<pre>
root 
 |-- <b>creationDate</b>: long (nullable = true) 
 |-- id: long (nullable = true) 
 |-- postTypeId: long (nullable = true)
 |-- tags: array (nullable = true)
 |    |-- element: string (containsNull = true)
 |-- title: string (nullable = true)
 |-- viewCount: long (nullable = true)
</pre>

<p>I would like to do some groupBy "creationData_Year" which need to get from "creationDate".</p>

<p>What's the easiest way to do this kind of convert in <em>DataFrame</em> using Java?</p>