Re:Ask HN: Timestamp vs. millis, storing time in database
by govindpatel on Thursday July 07, 2016 @09:34AM
(#12049183)
we have some tables where we have timestamp and other places we have millis. We are also using postgreSQL database.
I have asked this question so that I can know whether any other person faces problem like this, it is kind of annoying when I see different ways of storing the time, but not knowing what is the best practise to save time in database.
Using the native DBMS types allows use of native DBMS time and interval functionality, unless you like doing it yourself.
See also [2]
[1] https://www.postgresql.org/docs/9.6/static/datatype-datetime...
[2] http://stackoverflow.com/questions/409286/should-i-use-field...