[SOLVED] wheel of time()
Posted: Thu Sep 16, 2004 8:48 am
Hi
As PHP offers functions to return unix timestamps, i wonder what would be the best Date & Time format for a database (mySql) <-> PHP communication.
Shall I use PHPs unix timestamp in seconds, that is represented by an integer and therefore is running out of memory within the next couple of decades
(btw. does Unix by that time have a similar problem to the Y2K bug ? ) and use a <integer> field type in mySql.
On the contrary there are special mySqls time formats like <timestamp> or <datetime>, that are displayed in Y-M-D h
s, but need a little more converting in PHP.
So which is the most proper way, to work with timing information ? Any comment much appreciated , as always... _yak
As PHP offers functions to return unix timestamps, i wonder what would be the best Date & Time format for a database (mySql) <-> PHP communication.
Shall I use PHPs unix timestamp in seconds, that is represented by an integer and therefore is running out of memory within the next couple of decades
On the contrary there are special mySqls time formats like <timestamp> or <datetime>, that are displayed in Y-M-D h
So which is the most proper way, to work with timing information ? Any comment much appreciated , as always... _yak