MySQL FROM_UNIXTIME() with negative timestamp
2011-04-01 by xpheas
The MySQL FROM_UNIXTIME() function does not support negative epoch timestamps, it returns NULL.
I used the DATE_ADD function to work with negative timestamps:
I used the DATE_ADD function to work with negative timestamps:
BASH-Code:
| SELECT DATE_ADD(FROM_UNIXTIME(0), INTERVAL <timestamp> SECOND) FROM <table> |
« back