Derek Atkins warlord at MIT.EDU
Wed Jul 16 17:45:45 EDT 2008

Quoting "Stuart D. Gathman" <stuart at gathman.org>:

> On Wed, 16 Jul 2008, Derek Atkins wrote:
>> You haven't looked at the data file recently, have you?  Here's
>> an example from mine:
>>     <ts:date>2008-04-10 18:02:00 -0400</ts:date>
> The issue here isn't the data file (which I assumed we all agreed
> included the needed info).  The issue is that loading the
> nice ascii timestamp with timezone into just a time_t field in memory 
> (even a 64 bit one) loses critical info: the timezone.

This is where the "implicit TZ" comes in.  For example, what's
the difference between "2008-04-10 18:02:00 -0400" and
"2008-04-10 15:02:00 -0700"?   I would argue that there *is* no
difference.  Both timestamps are talking about the exact same time.
And hey look, they both say "2008-04-10".  Lookie there!

Unsurprisingly, both of these time stamps result in the same time_t value
in GMT.   But that's okay, if we fix the 0000 v. 1200 issue then
you don't need to know the original timezone all the time.

If you then change timezones then the data does get converted from one
representation to another.  But again, that's okay once we fix
the 0000 v 1200 bug.


       Derek Atkins, SB '93 MIT EE, SM '95 MIT Media Laboratory
       Member, MIT Student Information Processing Board  (SIPB)
       URL: http://web.mit.edu/warlord/    PP-ASEL-IA     N1NWH
       warlord at MIT.EDU                        PGP key available

More information about the gnucash-devel mailing list