08 Feb 2006
date '2006-01-01' - date '2006-03-01' is not 2 it is -2try this select date '2006-03-01' - date '2006-01-01' month as ActualMonthsthe result will be 2but the problem with this operation is select date '2006-03-22' - date '2006-01-01' month as ActualMonthsthe answer is 2 again. It will not display the data as 2 months XX days.
Hi!Someone knows how to calculate month difference between two dates?For example:=> date '2006-01-01' - date '2006-03-01' = 2 monthsI know that I could calculate by division, but it could be not exactly.=> date '2006-01-01' - date '2006-03-01' /30Thanks a lot.Natalia.