‎2008 Feb 21 1:16 PM
Hi All,
I am looking for a FM which should give me previous date after importing current date and Number of days( Range 1 to 365). Can you please let me know?
This is urgent.
Regards,
Md.
Edited by: Alvaro Tejada Galindo on Feb 21, 2008 10:38 AM
‎2008 Feb 21 1:21 PM
Hi,
use the foll FM HR_SEN_CALE_DAYS_DATE
Import parameters Value
ID_DATE 21.02.2008
ID_OPERATOR -
IS_DURATION 0.0000 0.0000 365.0000
Export parameters Value
ED_DATE 22.02.2007Cheers,
jose
‎2008 Feb 21 1:21 PM
Hi,
Could you please re-frame your question or give an example on what you are expecting?
Regards,
Yellappa.
‎2008 Feb 21 1:21 PM
Hi,
You don't need a function module for this, you can do it in one line of ABAP;
NEW_DATE = CURRENT_DATE - DAYS.
Where NEW_DATE and CURRENT_DATE ate date type variables.
Regards,
Nick
‎2008 Feb 21 1:32 PM
hope these function modules help you
HR_HK_DIFF_BT_2_DATES
diff between two dates
SD_DATETIME_DIFFERENCE
-difference in days and time for two dates
RP_CALC_DATE_IN_INTERNAL
RE_ADD_MONTH_TO_DATE ADD OR SUBSTRACTS MONTHS TO FROM DATE
<REMOVED BY MODERATOR>
Edited by: Alvaro Tejada Galindo on Feb 21, 2008 10:38 AM
‎2008 Feb 21 2:40 PM
Hi,
You can use FM RP_CALC_DATE_IN_INTERVAL.
If you wish to get previous spcify the days with -ve sign.
Thanks,
Sriram Ponna.
‎2008 Feb 21 3:26 PM
Use FM RP_CALC_DATE_IN_INTERVAL
For previous date,
Pass date as today's date
no. of days as 1
sign as '-'.
To get the next day's date,
Pass date as todays date
no of days as 1
sign as '+'
Hope this helps.
<REMOVED BY MODERATOR>
Thanks,
Balaji
Edited by: Alvaro Tejada Galindo on Feb 21, 2008 10:39 AM