I have 2 dates in DB2 UDB 8.
I want to do this calculation in the select clause :
If month(date1) - month(date2) = 0 then 'OVERDUE'
If month(date1) - month(date) = 2(example), then '2 Months OVERDUE'
If date1 = '09/02/2010' ( example) and date2 = '12/02/2008'(Example) then '21 Months OVERDUE'
Can someone kindly give me a solution to this?