MYSQL TIPS: MySQL difference between dates in number of days

If you're new here, you may want to subscribe to my RSS feed. One advantage of subscribing to RSS feeds is that you don't have to constantly re-visit this site to check for updates within specific sections you might be interested in because your browser or Feed reader will do this for you automatically on a regular basis plus you can even get email notification. Thanks for visiting!


[View FULL Article] To get a date difference in days in Mysql version before 4.1 (where you can use the datediff() function instead), do the following to calculate date difference:

select (TO_DAYS(date1)-TO_DAYS(date2))





Article copyright BookOfTips.Blogspot.Com - Find helpful tips that can help you with your daily activities. All rights reserved. No part of an article may be reproduced without the prior permission.




MYSQL TIPS: MySQL difference between dates in number of days - Related Tips / Tricks / Hacks



If you enjoyed this post Subscribe to our feed

No Comment

Post a Comment