spark-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Rabin Banerjee <dev.rabin.baner...@gmail.com>
Subject Re: write and call UDF in spark dataframe
Date Wed, 20 Jul 2016 10:51:07 GMT
Hi Divya ,

Try,

val df = sqlContext.sql("select from_unixtime(ts,'YYYY-MM-dd') as `ts` from mr")

Regards,
Rabin
On Wed, Jul 20, 2016 at 12:44 PM, Divya Gehlot <divya.htconex@gmail.com>
wrote:

> Hi,
> Could somebody share example of writing and calling udf which converts
> unix tme stamp to date tiime .
>
>
> Thanks,
> Divya
>

Mime
View raw message