View Single Post
Old 03-23-2007, 11:46 AM  
Varius
Confirmed User
 
Industry Role:
Join Date: Jun 2004
Location: New York, NY
Posts: 6,890
Quote:
Originally Posted by EDepth View Post
Or avoid mysql's functions, and just get the data then update the data
PHP Code:
$explode explode("-",$myrow['funkydatefield']);
$newDate $explode[2]."-".$explode[0]."-".$explode[1]; 
Or just work with unix timestamps in the DB for all date/time fields - that'smy preference.

However I think for Brad's purpose here doing it in mysql would be preferred instead of in the code...he could even use mysql's schedule feature to have it run every 5 mins or whatever he wishes, so no need to alter any code anywhere or even setup any cronjobs.
__________________
Skype variuscr - Email varius AT gmail
Varius is offline   Share thread on Digg Share thread on Twitter Share thread on Reddit Share thread on Facebook Reply With Quote