Application Development and Automation Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

Function to remove months to a date?

Former Member
0 Likes
1,459

Hi all,

There is a FM for remove months to a date?

tnx

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
1,391

hi,

check this fm <b>RP_CALC_DATE_IN_INTERVAL</b>

Regards

vijay

Hi all,

There is a FM for remove months to a date?

tnx

8 REPLIES 8
Read only

Former Member
0 Likes
1,391

explain it .what do u want to do?give example.

Read only

Former Member
0 Likes
1,391

Hi Fabrizio,

what do you mean with remove? Subtract?

Regards, Dieter

Read only

Former Member
0 Likes
1,392

hi,

check this fm <b>RP_CALC_DATE_IN_INTERVAL</b>

Regards

vijay

Read only

0 Likes
1,391

hi,

                                                                                
Import parameters               Value                                                                                
DATE                            10/10/2004                                         
  DAYS                            00                                                 
  MONTHS                          00                                                 
  SIGNUM                          -                                                  
  YEARS                           01                                                                                
Export parameters               Value                                                                                
CALC_DATE                       10/10/2003                                                                                

Read only

Former Member
0 Likes
1,391

yes... substract

Read only

Former Member
0 Likes
1,391

Hi

i use this

CALL FUNCTION 'RE_ADD_MONTH_TO_DATE'

EXPORTING

MONTHS = '-12'

OLDDATE = SY-DATUM

IMPORTING

NEWDATE = START_DATUM.

Regards, Dieter

Read only

Former Member
0 Likes
1,391

Perfect this FM: RP_CALC_DATE_IN_INTERVAL

Thanx all

Read only

Former Member
0 Likes
1,391

Hi,

U can substract months from the date by this FM.

CALL FUNCTION 'CALCULATE_DATE'

EXPORTING

DAYS = '0'

MONTHS = '-3'

START_DATE = SY-DATUM

IMPORTING

RESULT_DATE = res_date.

Rgds,

Prakash.

Note:- Reward points if helps.