Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

I, too, am a fan of ISO 8601. In an insane world of date formats, it's the only sane choice.

https://en.wikipedia.org/wiki/ISO_8601



Almost nobody is a fan of the actual ISO 8601. It requires a big 'T' to separate the date from the time - people consider this ugly and rarely implement this in the wild. People mostly use RFC 3339 which allows using a space instead of the 'T'.

Both also require colons to separate hours and minutes and this makes it impossible to use in file names if you want to support accessing them from Windows.

I personally use the actual ISO 8601 (with the "T") wherever I can, simple YYYY-MM-DD-HH-mm-SS-ffffff where I need to support saving to the file system (but this is slightly harder for a human to read) and mostly RFC 3339 (with a space instead of the "T") wherever I need to display or to interop with tools written by other people. As for SQLite - I usually store every field (years, months,... seconds etc) in a separate integer column and create a view which adds an automatically generated RFC 3339 date/time column for simpler querying.


Are ISO standards ever updated? Is there any chance we might see an ISO 8601 date variant which is meant for filenames?


> Are ISO standards ever updated?

Yes, ISO standards are updated as regularly as it makes sense for standards to change (obviously they wouldn't really be standards if they were updated more often).

Wikipedia says ISO 8601 was first published in 1988, with updates in 1991, 2000, 2004, and 2019.

The C language is another example. The latest stable revision (C17) is ISO/IEC 9899:2018.

> Is there any chance we might see an ISO 8601 date variant which is meant for filenames?

Hardly.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: