[wp-hackers] Re: Sqlite
peter.westwood at ftwr.co.uk
Sat Jun 25 11:09:29 GMT 2005
On Fri, June 24, 2005 8:37 pm, David Chait said:
> Ahhh, okay, there are two completely different threads going on here.
> One was about storing as unix timestamps instead of mysql DATETIME. The
> other, apparently, was about storing the timezone offset at time of post
> rather than the gmt timestamp at time of post.
> For the former, I'm all for it. Go to timestamps, nix DATETIME, makes it
> easier for alternate DB systems.
> For the latter, I can't say I care much either way. A gmt offset is only 24
> values (okay, 48 if you want half-hours), which is under a single byte. A
> timestamp is at least a 4-byte value. I don't know that saving three bytes
> per post makes any difference versus the constant recalc time, so I'm
> probably with mr. house on this one. SO, just store a gmt unix timestamp as
> well! All done? ;)
Assuming that the GMT offset is a integer number of hours or half hours is unfortunately not possible. The are a few
countries/regions with x:45 or x:15 offsets and it is quite possible that a country could legislate towards a
completely different offset if they so wished so we probably need to store the number of minutes to be safe.
If we are going to improve the storage of GMT offset then we probably need to improve/implement proper support for DST
because we can't assume that we can rely on the underlying system - however implementing full DST support can become a
nightmare (We have recently looked into this for work and I can dig up some references next week if any one is
Get Firefox: http://www.spreadfirefox.com/?q=affiliates&id=20287
More information about the wp-hackers