INTERACT FORUM

Please login or register.

Login with username, password and session length
Advanced search  
Pages: [1]   Go Down

Author Topic: LastPlayed in the export XML  (Read 2174 times)

vitopn

  • Member
  • *
  • Posts: 2
LastPlayed in the export XML
« on: February 11, 2007, 12:40:06 pm »

Couldn't find this in the documentation,  What does the Last Played field in the export xml represent? (so that I can convert it to a date)

How about the Date field?

Thank you,
-Vito

Logged

Alex B

  • MC Beta Team
  • Citizen of the Universe
  • *****
  • Posts: 10121
  • The Cosmic Bird
Re: LastPlayed in the export XML
« Reply #1 on: February 11, 2007, 01:43:14 pm »

I guess you didn't search the forum for the string "1970"  :)

http://yabb.jriver.com/interact/index.php?topic=37245.msg254398#msg254398
http://yabb.jriver.com/interact/index.php?topic=36906.msg251847#msg251847


The Date field seems to be a day counter.

- the number 1 represents December 31st, 1899
- the current date is 39124 (February 11th, 2007)
- December 30th, 1899 would be zero but that is not possible with the used logic and MC doesn't accept this value.
- December 29th, 1899 and older dates use negative numbers starting from -1
- if only the year number is in the Date field MC writes the date as January 1st of that year.


EDIT  1889 -> 1899
Logged
The Cosmic Bird - a triple merger of galaxies: http://eso.org/public/news/eso0755

vitopn

  • Member
  • *
  • Posts: 2
Re: LastPlayed in the export XML
« Reply #2 on: February 11, 2007, 01:51:45 pm »

Excellent.  Thank you for the super quick reply.

Cheers,
-Vito
Logged

Alex B

  • MC Beta Team
  • Citizen of the Universe
  • *****
  • Posts: 10121
  • The Cosmic Bird
Re: LastPlayed in the export XML
« Reply #3 on: February 11, 2007, 02:19:16 pm »

You're welcome.

I tried to find a reason for the odd looking December 31th, 1899 date. Why isn't it January 1st, 1900? Looks like this is the explanation:

And finally, why 30 December 1899? Why not, say, 31 December 1899, or 1 January 1900 as the zero day? Actually, it turns out that this is to work around a bug in Lotus 1-2-3! The details are lost in the mists of time, but apparently Lotus 1-2-3 used this date format but their devs forgot that 1900 was not a leap year. Microsoft fixed this bug by moving day one back one day.

That blog has explains some other date related oddities too.
Logged
The Cosmic Bird - a triple merger of galaxies: http://eso.org/public/news/eso0755
Pages: [1]   Go Up