Seriously, WTF?

Simon Burr simes at
Thu May 8 10:16:58 BST 2008

On Thu, May 08, 2008 at 10:33:43AM +0200, Luis Motta Campos wrote:
>Toby, I recommend you to seriously consider using strings or integers
>(depending on your range and precision needs) to hold dates, and relay
>on converting them to proper date types at the application side.

I've tended to find that storing seconds since epoch for date/time values
is easier in the long run. Especially if you're having to deal with multiple
timezones. It seems that one of the failings with DATETIME and similar is that
they don't tend to deal with timezones that well - certainly I've had to put
some truely blecherous hacks in place to deal with Sybase's "TZ ? I don't need
no stinking TZ!" attitude, combined with a similar attitude of the developers
who designed the tables.

   Simon the stressed           simes at
                 Chocolate is *not* a substitute for sleep

More information about the mailing list