Thursday, January 24, 2013

The way dates should be

Date formatting has long been a source of confusion for engineers and humans alike. In the U.S., the human standard is M/D/YY, while in the E.U., it's D/M/YY. IMHO, the euro standard is slightly better, because it progresses from smallest to largest, but it's still flawed. For one thing, it's often indistinguishable from the U.S. format: does 3/1/13 indicate January 3rd, or March 1st? Of course, if everyone used the Euro standard, then the ambiguity would be resolved, but my biggest complaint would remain: sorting. Both of these formats cause problems when sorted by a computer (for example, when sorting a directory of files by name). With either, March 3 2012 will be listed after January 1 2013. Fortunately, a solution is at hand.

So, here it is: the way dates should be:
YYYY-MM-DD

For example: 2013-01-24. Note the leading zero on the month (and this would apply to the day as well, if less than 10). This date format is unambiguous and will always be sorted correctly. I've taken to writing dates this way even in pen on paper, but I fear my one-man Occupy Date Format action will take a long time to catch fire. Still, I'm hoping to win converts. Meanwhile, I'm concerned with a more pressing debate over the order of things: the "R" and the "E" in the word "theater." Since TheaterMania (US) acquired WhatsOnStage (UK), we have divided opinions over whether it should be "theater" or "theatre." Again, there is a solution, and there is only one way the spelling of this word should be: we simply adopt Web 2.0 rules, and spell it theatr. Done and done.