from_unixtime {SparkR}R Documentation

from_unixtime

Description

Converts the number of seconds from unix epoch (1970-01-01 00:00:00 UTC) to a string representing the timestamp of that moment in the current system time zone in the given format.

Usage

from_unixtime(x, ...)

## S4 method for signature 'Column'
from_unixtime(x, format = "yyyy-MM-dd HH:mm:ss")

Arguments

x

a Column of unix timestamp.

...

further arguments to be passed to or from other methods.

format

the target format. See Customizing Formats for available options.

Note

from_unixtime since 1.5.0

See Also

Other datetime_funcs: add_months, date_add, date_format, date_sub, datediff, dayofmonth, dayofyear, from_utc_timestamp, hour, last_day, minute, months_between, month, next_day, quarter, second, to_date, to_utc_timestamp, unix_timestamp, weekofyear, window, year

Examples

## Not run: 
##D from_unixtime(df$t)
##D from_unixtime(df$t, 'yyyy/MM/dd HH')
## End(Not run)

[Package SparkR version 2.1.3 Index]