Skip to Content
author's profile photo Former Member
Former Member

regarding date calculations

Hi frnds,

I have to add date and duration fields when i m doing that

i am getting dummy values

it_departdate-departdate = it_departdate-departdate + it_departdate-duration.

suppose date is 01/29/06 and duration is 07.

so what shuld be done to get the date shuld be added.

the date format is like the same.

regards,

satish

Add a comment
10|10000 characters needed characters exceeded

Related questions

3 Answers

  • Posted on Jan 29, 2008 at 12:59 PM

    hi,

    simply add in ABAP:

    DATA : result TYPE date.

    DATA : departdate TYPE date.

    DATA : duration TYPE i.

    result = departdate + duration.

    hope this helps

    ec

    Add a comment
    10|10000 characters needed characters exceeded

  • author's profile photo Former Member
    Former Member
    Posted on Jan 29, 2008 at 01:00 PM

    any help frnds.

    Add a comment
    10|10000 characters needed characters exceeded

  • author's profile photo Former Member
    Former Member
    Posted on Jan 29, 2008 at 01:00 PM

    hi,,

    u have to create one temporariy internal table and

    loop at it_main.

    it_temd-date = it_main-date + it_main-duration.

    append it_temp.

    endloop.

    plzz reward if it is useful..

    plzz dont forget to reward.....

    Add a comment
    10|10000 characters needed characters exceeded

Before answering

You should only submit an answer when you are proposing a solution to the poster's problem. If you want the poster to clarify the question or provide more information, please leave a comment instead, requesting additional details. When answering, please include specifics, such as step-by-step instructions, context for the solution, and links to useful resources. Also, please make sure that you answer complies with our Rules of Engagement.
You must be Logged in to submit an answer.

Up to 10 attachments (including images) can be used with a maximum of 1.0 MB each and 10.5 MB total.