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

Date function.....Urgent

Former Member
0 Likes
681

Hi all,

i have to add 2 for the given date..

for example if i give the input as 01/02/2007

i need the outout as 03/02/2007

if i give the input as 31/01/2007

i need the output as 01/02/2007

please help me regarding this...

Thanks,

Navaneeth.

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
661

Hi ,

Use the standard function module.

DATE_IN_FUTURE

Regards,

IFF

Note: Reward Suitable points.

6 REPLIES 6
Read only

Former Member
0 Likes
661

date : d1 type d, d2 type d.

d2 = d1 + 2.

write d2.

Read only

Former Member
0 Likes
661

HI,

try this code

data: a type sy-datum,

b type sy-datum.

a = sy-datum.

b = a + 20.

write: / a , b.

regards,

venkatesh

Read only

Former Member
0 Likes
661

try in date in write statement

write 😕 date as mm/dd/yyyy. check the syntax

Read only

Former Member
0 Likes
662

Hi ,

Use the standard function module.

DATE_IN_FUTURE

Regards,

IFF

Note: Reward Suitable points.

Read only

0 Likes
661

Hi,

I got the solution..

Thanks,

Navaneeth

Read only

Former Member
0 Likes
661

Hi navaneethan,

Just declare the date as sy-datum and add or delete numbers system will take care.

Example :

data : w_date type sy-datum,

w_rdate type sy-datum.

w_rdate = w_date + 2.

This will do.