Home >Database >Mysql Tutorial >How to know the starting range of TIMESTAMP data type with the help of MySQL FROM_UNIXTIME() function?
As we all know, this function converts seconds to TIMESTAMP value. So, by providing 0 seconds as argument, it will give us the starting range of the TIMESTAMP data type.
mysql> Select FROM_UNIXTIME(0); +-------------------------+ | FROM_UNIXTIME(0) | +-------------------------+ | 1970-01-01 05:30:00 | +-------------------------+ 1 row in set (0.00 sec)
Now if we change the parameter from 0 to 60 seconds then the time will change by 01 minutes.
mysql> Select FROM_UNIXTIME(60); +-------------------------+ | FROM_UNIXTIME(60) | +-------------------------+ | 1970-01-01 05:31:00 | +-------------------------+ 1 row in set (0.00 sec)
The above is the detailed content of How to know the starting range of TIMESTAMP data type with the help of MySQL FROM_UNIXTIME() function?. For more information, please follow other related articles on the PHP Chinese website!