Live data from Hacker News

Timestamps done right

getkerf.wordpress.com

71–74 of 74 posts

Re: Timestamps done right

#71

  Numericaly sortable date [YYYY+][mm][dd].[HH][MM][SS],[NNNNNNNNN]
  date -u +%Y%m%d.%H%M%S,%N
  20160122.044145,052215000

  Absolute dates with nanos as seconds since epoch
  date -u +%s.%N
  1453437715.409682000

  Hyphenated,"chunks", with nanos and TZ offset.
  date -uIns
  2016-01-22T04:41:03,121501000+0000

Re: Timestamps done right

#74
post #3

Why are we not using unix timestamps (seconds since the epoch) for timestamps on everything that doesn't require sub-second precision?

You still need to record the timezone somewhere and you might as well just stick to ISO8601/RFC3339 format then.

No I don't. UTC.
Post reply on HN