07-11-2007 3:59 PM
Hi,
Is there any fun.module which will caluculate the difference between two dates and time excluding weekends?
Thanks in advance.
Srini.
07-11-2007 4:04 PM
Hi Srinivasa,
Use thif FM <b>RKE_SELECT_FACTDAYS_FOR_PERIOD</b>
Regards
Aneesh.
07-11-2007 4:04 PM
07-11-2007 4:06 PM
REPORT ZEXAMPLE.
DATA V_DIFF TYPE I.
PARAMETERS P_BIRTHD LIKE SY-DATUM.
Sample code::
CALL FUNCTION 'DAYS_BETWEEN_TWO_DATES'
EXPORTING
I_DATUM_BIS = SY-DATUM
I_DATUM_VON = P_BIRTHD
IMPORTING
E_TAGE = V_DIFF
EXCEPTIONS
DAYS_METHOD_NOT_DEFINED = 1
OTHERS = 2.
07-11-2007 4:09 PM
Hi Srini,
Use the following FM
SD_DATETIME_DIFFERENCE
which Give the difference in Days and Time for 2 dates
Reawrd points if helpful.
Regards
Srikanta Gope
srikanta.gope@tcs.com
07-11-2007 6:51 PM
Hi,
It will include weekends..but I want to exclude weekends while calculating difference.
Thanks
Srini.
07-11-2007 7:09 PM
07-12-2007 12:49 PM
Hi,
Refer to the following link:
http://sap-img.com/abap/function-to-return-next-business-day.htm
Hope this helps.
Reward if helpful.
regards,
Sipra
07-11-2007 4:23 PM
<b> /SDF/CMO_DATETIME_DIFFERENCE</b>
check with it..
Reward if helpful..
Regards
Prax
07-11-2007 4:31 PM
Hi,
Try functions,
=> DATE_CONVERT_TO_FACTORYDATE
=> HR_HK_DIFF_BT_2_DATES
Regards,
Bhaskar