Page 1 of 1

Timestamp

Posted: Sun Feb 09, 2003 12:30 pm
by thoughtriot
Ok, I have a timestamp field in a table, and I can insert values into it fine, but how would I extract the field in the format m.d.y? Because if I just extract the timestamp field normally like all the other fields, it comes out in a format I don't want. And also, how would I echo the timestamp field after I extract it. Thanks.

Posted: Mon Feb 10, 2003 2:53 am
by twigletmac
You can format the timestamp using MySQL's DATE_FORMAT function:
http://www.mysql.com/doc/en/Date_and_ti ... ml#IDX1282
Then you can just echo the result without doing anything to it.

Mac