You can convert the timestamp to date in mysql by using DATE and FROM_UNIXTIME function. The command given bellow,
> SELECT DATE( FROM_UNIXTIME( `created` ) ) AS pDate FROM phpkit
OUTPUT as follows,
------------------------------
2008-07-14
------------------------------
> SELECT DATE( FROM_UNIXTIME( `created` ) ) AS pDate FROM phpkit
OUTPUT as follows,
------------------------------
2008-07-14
------------------------------
0 comments:
Post a Comment