Working with datetime type in Quickbooks My Time files
Posted
by
jakemcgraw
on Stack Overflow
See other posts from Stack Overflow
or by jakemcgraw
Published on 2011-01-06T04:42:58Z
Indexed on
2011/01/06
5:54 UTC
Read the original article
Hit count: 259
I'm attempting to process Quickbooks My Time imt files using PHP. The imt file is a plaintext XML file. I've been able to use the PHP SimpleXML library with no issues but one:
The numeric representations of datetime in the My Time XML files is something I've never seen before:
<object type="TIMEPERIOD" id="z128">
<attribute name="notes" type="string"></attribute>
<attribute name="start" type="date">308073428.00000000000000000000</attribute>
<attribute name="running" type="bool">0</attribute>
<attribute name="duration" type="double">3600</attribute>
<attribute name="datesubmitted" type="date">310526237.59616601467132568359</attribute>
<relationship name="activity" type="1/1" destination="ACTIVITY" idrefs="z130"></relationship>
</object>
You can see that attritube[@name='start'] has a value of:
308073428.00000000000000000000
This is not Excel based method of storage 308,073,428 is too many days since 1900-01-00 and it isn't Unix Epoch either.
So, my question is, has anyone ever seen this type of datetime representation?
© Stack Overflow or respective owner