X
X
X
X

Calculating the Time Difference Between Two Dates With Mysql

HomepageArticlesWeb designCalculating the Time Difference Bet...

A life-saving method for calculating the time difference between two dates in MySQL on a Decimated basis.

time_to_sec(timediff(CURRENT_TIMESTAMP(), date)) / 60 as t
Finds and calculates the difference in minutes. If you divide by 3600, it will give you the result on a day-by-day basis.


Top