5 ms·
The real purpose of endianness which is missed here is the ability to sort. Sorting a list of iso8601 dates alphabetically means sorting them chronologically to
by kitd 6y ago
The real purpose of endianness which is missed here is the ability to sort. Sorting a list of iso8601 dates alphabetically means sorting them chronologically too.
- deleted 6y ago[deleted]
- k_sze 6y agoUntil we hit year 10000, but yeah, that's still a looong time to go.
- est 6y agoThere's some proposal that this year 2021 is actually 12021, to make the year neutral of some specific religious event.
- ComputerGuru 6y agoI know you’re not saying you are encouraging it and it’s just a related but of trivia, but I find that hilarious. Because when someone asks “why start there?” the answer “it’s a thousand years before Jesus Christ was born, the millennium heralding his arrival” is better? (I’m not even Christian but I also don’t have a chip on my shoulder and can accept its influence on the world)
- bhaak 6y agoIt's ten thousand years before the assumed (but likely wrong) birthday of Jesus Christ, to have a positive date for all written human history (well, until we find the archives of Atlantis) and an easy round offset for the prevalent human calender in use.
- grey_earthling 6y agoThe answer is “because -10000 CE is an approximation of the beginning of human civilisation, using this epoch removes negative year numbers from all historical dates, and it's simple to convert from the ubiquitous CE epoch”. https://en.wikipedia.org/wiki/Holocene_calendar https://en.wikipedia.org/wiki/Holocene_calendar
- mattashii 6y ago... which is funny, because the gregorian calendar is supposedly based on a compromise between some years that christ was supposedly born in (the chosen year 1 is none of those, according to research, as he was born in 6-4 BC [0]). So now we have: another calendar, that has a starting year that is defined by subtracting an arbitrary number from a compromise between alledged years some person was born in. I love how humanity has the capability to invent new things with increasing complexity. [0] https://en.wikipedia.org/wiki/Anno_Domini#Birth_date_of_Jesus https://en.wikipedia.org/wiki/Anno_Domini#Birth_date_of_Jesu...
- TeMPOraL 6y agoYup. I have a calendar for 12021 hanging in my office, and I very like the sentiment it expresses. I tried to use the Holocene years with other people, but they remain unconvinced.
- eesmith 6y agoIt's there: > This not only makes all of the dates look equally nice, but also, coupled with other quirks of this format, allows the files with the date in the name to be sorted just by the filename. My issue is with: > Simplified, the core date format looks like this: yyyy-mm-dd hh:mm:ss Here are the examples at https://en.wikipedia.org/wiki/ISO_8601 https://en.wikipedia.org/wiki/ISO_8601 2021-02-26T06:22:59+00:00 2021-02-26T06:22:59Z 20210226T062259Z Note the "T" instead of a space between the date and time? That's what the spec says: https://en.wikipedia.org/wiki/ISO_8601#Combined_date_and_time_representations https://en.wikipedia.org/wiki/ISO_8601#Combined_date_and_tim... . "Separating date and time parts with other characters such as space is not allowed in ISO 8601, but allowed in its profile RFC 3339." Note the optional use of "-" and ":"? That's "basic" vs. "extended" formats. Plus the optional timezone specifier (if not present, assume it's the same timezone). There's also optional support for microseconds.
- kirbykevinson 6y agoI omitted this detail on purpose to not distract the reader who doesn't know much about date formats.
- eesmith 6y agoHow would you describe the accuracy and veracity of > "Here there’s only one correct way to write a date," given that there are multiple correct ways, and the way shown wasn't actually ISO 8601 but RFC 3339?
- kirbykevinson 6y agoYes, technically there are some edge cases where you can write things differently (apart from what you mentioned, one is, for example, writing the UTC time zone by Z vs +00:00 and another is adding additional precision to the date), but for the end user it's basically the same. Let's not ruin the illusion here :)
- eesmith 6y ago
- mjevans 6y agoThat's also the only time (full) European dates make sense, when writing them on the right hand side of a ledger page so that the exterior of the ledger / book is indexed with the largest components on the edge of the page. US dates only make sense if you don't care about the year and are writing on the left most side of a page; that might make sense if ink or paper is at a premium.
- orwin 6y agoMy great great grandfather wrote a book about this 120 years ago! And yes, it was for taxes and accounting.
- nayuki 6y agoWhat you said about European dates (e.g. 27/02/2021 today) is not strictly true. The rightmost character is the ones digit of the year, and it is not the largest component. According to your rules, 01/01/2019 would be "larger" than 01/01/2021 because 9 is larger than 1. The blog post already made this observation, saying that YMD is the only format where the endianness of the date components match the endianness of the numbers; DMY does not have this property. If you wanted to sort dates correctly on the right hand side, you need to write the numbers backwards too, like "72/20/1202".