zgkhoo Posted November 6, 2007 Share Posted November 6, 2007 currrent i store this date('Y-m-d H:i:s'); into mysql DB but i after i changed to date('d/m/y H:i:s'); then it become empty value just 0000-00-00 00:00:00 is it the problem cause by incompatible format for date('d/m/y H:i:s'); and my DateJoin datetime(mysql field type) format? Quote Link to comment Share on other sites More sharing options...
fenway Posted November 6, 2007 Share Posted November 6, 2007 currrent i store this date('Y-m-d H:i:s'); into mysql DB but i after i changed to date('d/m/y H:i:s'); then it become empty value just 0000-00-00 00:00:00 is it the problem cause by incompatible format for date('d/m/y H:i:s'); and my DateJoin datetime(mysql field type) format? Don't change how to store it... it was correct. If you want it back different, use DATE_FORMAT(). Quote Link to comment Share on other sites More sharing options...
zgkhoo Posted November 6, 2007 Author Share Posted November 6, 2007 this is for convert? Quote Link to comment Share on other sites More sharing options...
fenway Posted November 6, 2007 Share Posted November 6, 2007 this is for convert? All SQL dates are stored in a standard format... so you have to store it that way too (and you should). You can request it in any way you want. Quote Link to comment Share on other sites More sharing options...
Barand Posted November 6, 2007 Share Posted November 6, 2007 zgkhoo, Are we wasting our time telling you anything in these forums. I told you the format to store dates 3 days ago http://www.phpfreaks.com/forums/index.php/topic,166229.msg731657.html#msg731657 Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.