On 17.6.2011 16:08, Thomas Mueller wrote:
That was how H2 stored dates in older version, but it was very
problematic (exactly because of problems when changing the timezone).
Hi Thomas,
You gotta walk me through this so I understand.
If you have a timepoint in UTC then it does not matter in which timezone
you are.
It stays the same.
So if you move the server or change it's timezone, then it should not
have the least bit of difference to that timepoint in UTC.
Now, I do understand that when formatting the timestamp one needs to use
a timezone and locale.
And if the user does not define which timezone and locale he wishes to
use then a default must be used.
And if it is the default timezone and locale of the server which are
used as defaults then changing those defaults will change
the results of formatting the time from it's original bigint representation.
So if some users do not understand this and get into trouble, is that
reason enough to punish those who do understand this
and make their timezone aware applications even more difficult to implement?
So in the future if we would like to please both groups we could have
two different timestamps, with and without a timezone.
This we have already discussed.
But funnily the timestamp WITHOUT the timezone would store the timestamp
WITH the timezone and never be affected by
server or client defaults for timezone but always use the timezone in
which they were created which by the way would be defined
most probably by the server default of which the silly user would not be
aware of.
But the timestamp WITHOUT the timezone would not support giving
explicitly the timezone in temporal functions. It would always stay the
same.
We do start to get into real mess when we start comparing timestamp
WITHOUT timezone and timestamp WITH timezone...
So what we mean in this scenario is that timestamp WITHOUT timezone is
actually timestamp WITH-A-STATIC timezone, right?
- rami
--
You received this message because you are subscribed to the Google Groups "H2
Database" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/h2-database?hl=en.