On 20 April 2010 17:40, Floyd Resler <fres...@adex-intl.com> wrote:

> I need to get the difference in months between two dates.  The dates could
> be as much as 60 months apart.  Is there any easy way to do this either
> through PHP or MySQL?  I know how I can do it through code but thought there
> might be a simple one or two line option.
> Thanks!
> Floyd
You're best off doing this in MySQL.
Something like select timestampdiff(month, '2010-01-01', '2010-05-22');
should work.


Reply via email to