‎2006 Nov 29 1:38 PM
Hello,
Is there any function module available for giving the difference between two dates.
For ex:
date1 = 01/30/2000; date2: 02/30/2002
If I query for difference it should in below format :Years & Months.
i.e the difference between date2 & date1 should be shown as 2 years 1 month.
Thanks,
Kanaka
‎2006 Nov 29 1:43 PM
hi,
Use FM <b>RKE_SELECT_FACTDAYS_FOR_PERIOD</b> or use FM <b>'DAYS_BETWEEN_TWO_DATES'</b>
Regards,
Santosh
‎2006 Nov 29 1:43 PM
hi,
Use FM <b>RKE_SELECT_FACTDAYS_FOR_PERIOD</b> or use FM <b>'DAYS_BETWEEN_TWO_DATES'</b>
Regards,
Santosh
‎2006 Nov 29 1:43 PM
hi,
There is no need of any function module for knowing the differnece in dates.
v_diff_days = date1 - date2.
You get the difference in no of days.
Later you can divide it by 365 and know the difference in years.
v_yrs = v_diff_days/365.
Regards,
Sailaja.
‎2006 Nov 29 1:44 PM
Hi Kanaka,
You can use the function module <b>HR_HK_DIFF_BT_2_DATES</b> for finding the difference between two dates in your desired format.
Regards,
Vinod.
‎2006 Nov 29 1:46 PM