Hi,
On 04/29/2013 11:47 AM, Thilo Bangert wrote:
I'd just save one timestamp, ie TAI64 or as java
does miliseconds since epoch,
in a single, new field. saving the timestamp in two fields seems messy.
Agreed.
miliseconds since epoch is probably preferable, since
it can be converted to
human readable dates by the database server.
What I like about the DECIMAL approach is that it's (at least in MySQL)
usable with from_unixtime functions, in case you need quick access to
human readable format. Up until 5.1 it only shows seconds precision in
that case, not sure about high resolution precision in 5.6 where
timestamp seems to support microseconds.
Also not sure about compatibility with other DB engines.
Andreas