Live data from Hacker News

'Japan's millennium bug' ahead of Akihito's abdication

theguardian.com

1–10 of 99 posts

Re: 'Japan's millennium bug' ahead of Akihito's abdication

#4
post #2

How pervasive is the Japanese calendar in computing actually? I suppose most programs calculate all dates internally using UNIX timestamps or UTC and only convert that to Japanese dates for display purposes. Anybody has any experience with this?

I was thinking this exactly. Not much of a problem for data, more of a problem for display of the data. A good stop-gap until they get enough information about the new era would be to just display the dates in UTC for a while or something.

I mean, unless they're storing the date/time in the database as a string, formatted for Japan's locale. Then they're screwed, kind of. I mean even then, it could be fixed with a stored procedure within an update statement.

Re: 'Japan's millennium bug' ahead of Akihito's abdication

#6
post #2

How pervasive is the Japanese calendar in computing actually? I suppose most programs calculate all dates internally using UNIX timestamps or UTC and only convert that to Japanese dates for display purposes. Anybody has any experience with this?

I was thinking this exactly. Not much of a problem for data, more of a problem for display of the data. A good stop-gap until they get enough information about the new era would be to just display the dates in UTC for a while or something. I mean, unless they're storing the date/time in the database as a string, formatted for Japan's locale. Then they're screwed, kind of. I mean even then, it could be fixed with a st…

I'm sure some unfortunate developer in Japan has made this mistake as I've seen datetimes stored as strings in America.

There's also probably logic in UIs somewhere that uses the string representation for something more critical than you'd expect.

Re: 'Japan's millennium bug' ahead of Akihito's abdication

#7
post #2

How pervasive is the Japanese calendar in computing actually? I suppose most programs calculate all dates internally using UNIX timestamps or UTC and only convert that to Japanese dates for display purposes. Anybody has any experience with this?

I was thinking this exactly. Not much of a problem for data, more of a problem for display of the data. A good stop-gap until they get enough information about the new era would be to just display the dates in UTC for a while or something. I mean, unless they're storing the date/time in the database as a string, formatted for Japan's locale. Then they're screwed, kind of. I mean even then, it could be fixed with a st…

As much as using UTC would be better, I suppose for many that will not be an option if they are accustomed to Japanese dates. I mean, I got flak in work because I was writing dates (as in, written on printed paper) in the ISO-8601 format and apparently the administration in France does not understand that.

Re: 'Japan's millennium bug' ahead of Akihito's abdication

#8
post #2

How pervasive is the Japanese calendar in computing actually? I suppose most programs calculate all dates internally using UNIX timestamps or UTC and only convert that to Japanese dates for display purposes. Anybody has any experience with this?

I don't think that's the problem; I think that's the one thing that's not a problem. Monotonic time is not that hard. The hardest thing about it is just convincing programmers to use it, and making sure your libraries use it properly. I don't want to say it's trivial, but it's not that hard once both you and your code base internalize "convert everything to internal UTC representation as quickly as possible, convert to local time as late as possible on the way out".

It's everything else that's a problem. It's the places where you input the Japanese time, and there's an era that the code has never heard of for some old system. There is no way for that system to even conceivably handle it without some sort of update, at least a database update. They're talking about creating a new character for the era, which literally no system on Earth can currently use because it doesn't even exist yet, and, again, anything old that can't be updated can't conceivably display it correctly. They might be able to display it as the individual characters, but they still won't know that's a date, or that they have to. As mipmap04 says, it's where Japanese dates were stored as a string or something, because goodness knows I've seen enough US dates stored as strings.

And inferring from the article that the tax authority is going to extend the old era, I assume that at the very least a good chunk of the government works on Japanese dates, so it's going to be important not to, say, print tax forms that have � in the date, etc.

Re: 'Japan's millennium bug' ahead of Akihito's abdication

#9
post #2

How pervasive is the Japanese calendar in computing actually? I suppose most programs calculate all dates internally using UNIX timestamps or UTC and only convert that to Japanese dates for display purposes. Anybody has any experience with this?

I was thinking this exactly. Not much of a problem for data, more of a problem for display of the data. A good stop-gap until they get enough information about the new era would be to just display the dates in UTC for a while or something. I mean, unless they're storing the date/time in the database as a string, formatted for Japan's locale. Then they're screwed, kind of. I mean even then, it could be fixed with a st…

There are all kinds of random places where this has potential to show up. For example, some backend process breaking (or worse, silently discarding data) because of validating dates in incoming data from another system as a string regex that expects the old era symbol.

Re: 'Japan's millennium bug' ahead of Akihito's abdication

#10
post #2

How pervasive is the Japanese calendar in computing actually? I suppose most programs calculate all dates internally using UNIX timestamps or UTC and only convert that to Japanese dates for display purposes. Anybody has any experience with this?

I've just been on a 3 week trip to Japan and didn't see traditional Japanese dates used anywhere except on museum exhibits. Train tickets, bus tickets, hotel check-in / out dates, credit card receipts, tickets for various attractions etc. all displayed the date in ISO-8601 format.

It's interesting to ponder, but the traditional date format seems to have fallen out of use (probably with the advent of the computer era) and I genuinely don't think that this will be a problem.

Post reply on HN