bradkenyon Posted September 12, 2008 Share Posted September 12, 2008 stupid me entered dates into the table poorly. here is a screen shot of how they are entered. YYYY-MM-DD HH:MM:SS When it should be YYYYMMDDHHMMSS How could I go about running a query to change them appropriately in the table? Thanks in advance. [attachment deleted by admin] Quote Link to comment Share on other sites More sharing options...
PFMaBiSmAd Posted September 12, 2008 Share Posted September 12, 2008 The format is correct for a DATETIME data type and does not need to be changed. What problem are you having? Quote Link to comment Share on other sites More sharing options...
bradkenyon Posted September 12, 2008 Author Share Posted September 12, 2008 I thought the proper format that is wise to use is YYYYMMDDHHMMSS? I just want to make sure I am being the most efficient? Quote Link to comment Share on other sites More sharing options...
PFMaBiSmAd Posted September 12, 2008 Share Posted September 12, 2008 What data type are your columns? You can provide either a YYYY-MM-DD HH:MM:SS or YYYYMMDDHHMMSS value and it will be uses as YYYY-MM-DD HH:MM:SS in a DATETIME data type. Quote Link to comment Share on other sites More sharing options...
bradkenyon Posted September 12, 2008 Author Share Posted September 12, 2008 It is datetime. So its alright to leave as is? I just want to be sure I am following proper guidelines, so it doesn't bite me in the butt later on. Quote Link to comment Share on other sites More sharing options...
PFMaBiSmAd Posted September 12, 2008 Share Posted September 12, 2008 http://dev.mysql.com/doc/refman/5.0/en/datetime.html Quote Link to comment Share on other sites More sharing options...
revraz Posted September 12, 2008 Share Posted September 12, 2008 Yes, they are fine as they are. 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.