How to get UNIX TIMESTAMP in ERLANG
If you want to get UNIX TIMESTAMP which means number of seconds starting from Thursday, 1 January 1970, You can use following command.
calendar:datetime_to_gregorian_seconds
(calendar:now_to_universal_time( now()))-719528*24*3600.
Labels: UNIX TIMESTAMP

0 Comments:
Post a Comment
Subscribe to Post Comments [Atom]
<< Home