Issue: there are 27 different ways of writing a date.
Engineers: We most make a common standard that is unambiguous, easy to understand and can replace all of these.
Issue: there are 28 different ways of writing a date.
Joke aside, I really think the iso standard for dates is the superior one!
2013-02-27 = 1984
2013-02-27 is a weird way of writing 1361923200
I agree with the ISO approach, but unfortunately without mainstream adoption in a majority of countries it’s just another standard.
In the last company I work for, the department was created from zero, and my boss just let me take all the technical decisions so from the begging everything was wrote in ISO-8601. When I left it was just the way it was, if you try to use any other date format anywhere something is going to give you an error.
This is the way.
@[email protected] this might be applicable to the farside as well
Do you mean the post titles? I’ve been using the same format as was used since before I took over posting, but if people want ISO format that works for me
The sane way of dealing with it is to use UTC everywhere internally and push local time and local formatting up to the user facing bits. And if you move time around as a string (e.g. JSON) then use ISO 8601 since most languages have time / cron APIs that can process it. Often doesn’t happen that way though…
The BEST way is to use the number of seconds after the J2000 epoch (The Gregorian date January 1, 2000, at 12:00 Terrestrial Time)
Generally yes, that’s the way to do it, but there are plenty of times where you need to recreate the time zone something was created for, which means additionally storing the time zone information.
Definitely. If your servers aren’t using UTC, then when you’re trying to sync data between different timezones, you’re making it harder for yourself.
This is what I try to do in the few apps I’ve written that had to deal with dates and times
People aren’t computers.
I think you skipped part of the sentence.
I propose that we amend the ISO to require the days of the week be named after their etymological roots in that language.
English Days of the Week:
Day of the Sun
Day of the Moon
Day of Týr
Day of Odin
Day of Thor
Day of Frēa
Day of SaturnImagine dating a meeting, “Day of Odin, May 7, 2025.” Imagine a store receipt that says, “Day of Thor, June 5, 2025.” Imagine telling a friend, “July 4th falls on a Day of Frēa this year!”
THIS IS WHAT WE COULD HAVE. THIS IS WHAT WE HAVE LOST. THIS IS WHAT WAS STOLEN FROM US.
We could bring it back. We could make this the norm. We could make this real. We could summon this bit of ancient magic back into our world. Let’s remember what we actually named these days for! BRING BACK THE DAY OF THOR!
That would work better if Latin wasn’t there before English. Mars Victor!
Where I live, “DD. MM. YYYY” is the standard but some old tombstones use
Do you know why one would ever do that? 20(02/05)25 feels like the “Don’t Dead Open Inside” of dates.
Which is exactly why they’re used on tombstones. See, the world makes sense after all!
That’s just a layout. Let’s not confuse presentation with content.
I am a big fan of iso 8601, I just wish it was possible to write more dates than February 27th, 2013 with it
Yeh but for that one day though, everything just works so well.
Harhar
ISO 8601 allows all kinds of crazy time stamps. RFC 3339 is much nicer and simpler, and the sweet spot is at the intersection of ISO 8601 and RFC 3339.
Then again, ISO 8601 contains some nice things that RFC 3339 does not, like ranges and durations, recurrences…
Rich is right, since this is the date format that sorts correctly in filenames.
And it is easily extensible to YYYY-MM-DDThh:mm:ss to include the time of day
Are you an obsidian user?
I feel called out and I’m hiding in the bushes reading comments.
Haha yep, you caught me. I’m a fan of the unique note feature
Won’t be true after 9999-12-31, however.
If I, my software, or my data last this long, I will have nearly 8000 years to resolve it. Which is to say, the year 9998 is going to get busy.
Oh no! The Y10K bug!
Can’t wait for the Y40k bug, when Tyranids begin to infect our brains.
Bold of you to assume there isn’t already a genestealer cult on Terra. Washington specifically.
That…would explain a lot
If humanity survives until then, we can implement 9-digit dates and delay the problem until Y100K.
Can be solved with a small shellscript adding a leading zero to all filenames with the format.
natural sort ftw
I’d be curious to see a sorting algorithm that doesn’t handle YYYYY-MM-DD with YYYY-MM-DD properly. If you drop the dashes you still get a proper numeric order. If you sort by component, you still get the proper order. Maybe a string sort wouldn’t? Off the top of my head the languages I’m thinking either put longer strings later, giving us the proper order, or could put 1YYYY- ahead of 1YYY-M so maybe string sorting is the only one that’s out.
Lexical sorting (string sorting/alphabetical order sorting) is what I believe they were referring to when talking about file names.
The fact that you don’t have to do any parsing of the string at all, just do a straight character-by-character alphabetical sort, and they will be sorted by date, is a great benifit of this date scheme. That means in situations where no special parsing is set up (eg, in a File Explorer windows showing a folders contents sorted alphabetically) or where your string isn’t strictly date only (eg, a file name format such as ‘2025-05-02 - Project 3.pdf’) you can still have everything sorted by date just by sorting alphabetically.
Its this benifit that is lost when rolling over to 5-digit years.
I bet you could make a one liner to rename files with YYYY-MM-DD to 0YYYY-MM-DD fairly easily. Not a problem.
It’s an easy fix at least, just check if you’re comparing numbers on both sides and switch to a simple numerical sort.
I think Windows used to get this wrong, but it was fixed so long ago that I’m not even sure now.
Who’s Rich? Did you mean Randall?
…dammit, the only comics I read are XKCD and OOTS and I done fucked up.
How can you sleep on Oglaf
Banished to back in time to hang with Ozy and Millie
The good ones tend to filter their way out.
(I do also read whatever John Allison is currently working on.)
Omg thank you!! Everyone sees my notes thinks I’m crazy for obsessing… It’s the correct fucking sort!
My goodness, some of the comments in here must come from people who thought that those writing the standard were morons who did no research.
I don’t think they’re morons…just slaves to convention and compatibility. Not many ways to get away from that and justify it.
Alt text:
ISO 8601 was published on 06/05/88 and most recently amended on 12/01/04.
But… that’s not the right way. Are you saying the ISO8601 violates ISO8601?
- so, apparently not I just whooshed, I didn’t even noticed the dates are ambiguous.
The joke is that they’ve not been given in ISO8601 format, and also that they’re both ambiguous. For the second one, we can’t even tell which of the ends is the year.
Honestly Randall absolutely would put the year in the middle just to fuck with us
Publication 1988-06-05, latest amendment 2004-12-01.
I almost expected the two dates to use different formats, but no, they’re just both “the American way”.
Well you can only cram in so many jokes at once. Would have been funny though
Knowing Americans it’s probably the middle.
You found the joke
Might be the best xkcd alt text of all time. I knew if from memory, and as soon as I saw the comic I thought “I bet someone quoted the alt text in the top comment”.