Posted By

flashmac on 09/08/10


Tagged

mysql php date


Versions (?)

Who likes this?

3 people have marked this snippet as a favorite

roli000
kidmizere
virendrakryadav


Display MYSQL date as readable to us humans


 / Published in: MySQL
 

  1. SELECT DATE_FORMAT(dateColumnName, '%m/%d/%Y %h:%i %p') AS whatever
  2.  
  3. ------------------------ RESULT ------------------------
  4.  
  5. //Turns MySQL DATE FROM this
  6. 2009-12-25 16:25:00
  7.  
  8. //TO THIS
  9. Ho Ho Ho, It's Christmas!! (Just kidding)
  10.  
  11. //TO THIS (HONEST)
  12. 25/12/2009 16:25 PM

Report this snippet  

You need to login to post a comment.