Too Cool for Internet Explorer

MySQL Birthday Column – Age of a Person   July 8th, 2009

If you search for a solution to get the age of a person (in years) in MySQL, google gives you many obsolete (and complicated) answers, from MySQL 4.1.1 it is very easy to get this number:

TIMESTAMPDIFF(YEAR, myDateColumn, NOW())

Have fun.

Tags: , , , ,
This entry was posted on Wednesday, July 8th, 2009 at 23:06 and is filed under Programming. You can follow any responses to this entry through the RSS 2.0 feed.You can leave a response, or trackback from your own site.

No Responses

Leave a Reply