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

First date and last date of current year

Hi

how can i get first and last date of current year, thanks for your help

Add a comment
10|10000 characters needed characters exceeded

Assigned Tags

Related questions

7 Answers

  • Best Answer
    author's profile photo Former Member
    Former Member
    Posted on Jan 09, 2007 at 02:51 PM

    try this

    <b>FIRST_AND_LAST_DAY_IN_YEAR_GET</b>

    Add a comment
    10|10000 characters needed characters exceeded

  • author's profile photo Former Member
    Former Member
    Posted on Jan 09, 2007 at 02:50 PM

    Hi

    FIRST_DAY(4) = SY-DATUM(4).

    FIRST_DAY+4(4) = '0101'.

    LAST_DAY(4) = SY-DATUM(4).

    LAST_DAY+4(4) = '1231'.

    Max

    Add a comment
    10|10000 characters needed characters exceeded

  • Posted on Jan 09, 2007 at 02:50 PM

    You can do that very simply like so.

    
    report zrich_0001.
    
    data: first type sy-datum.
    data: last type sy-datum.
    
    
    first = sy-datum.
    first+4(4) = '0101'.
    last  = sy-datum.
    last+4(4) = '1231'.
    
    write:/ first, last.
    
    

    Regards,

    Rich Heilman

    Add a comment
    10|10000 characters needed characters exceeded

  • author's profile photo Former Member
    Former Member
    Posted on Jan 09, 2007 at 02:52 PM

    Hello,

    U an do it like this.

    Data: lf_datum like sy-datum,

    lf_datum1 like sy-datum.

    TO get first date

    lf_datum0(4) = sy-datum0(4).

    lf_datum+4(2) = '01'.

    lf_datum+6(2) = '01'.

    Last date

    lf_datum10(4) = sy-datum0(4).

    lf_datum1+4(2) = '12'.

    lf_datum1+6(2) = '31'.

    If useful reward.

    Vasanth

    Add a comment
    10|10000 characters needed characters exceeded

  • author's profile photo Former Member
    Former Member
    Posted on Jan 09, 2007 at 02:50 PM
    FIRST_AND_LAST_DAY_IN_YEAR_GET
    

    Greetings,

    Blag.

    Add a comment
    10|10000 characters needed characters exceeded

  • author's profile photo Former Member
    Former Member
    Posted on Jan 09, 2007 at 02:51 PM

    hi,

    use FM......... FIRST_AND_LAST_DAY_IN_YEAR_GET

    DATA: first LIKE sy-datum,

    last LIKE sy-datum.

    CALL FUNCTION 'FIRST_AND_LAST_DAY_IN_YEAR_GET'

    EXPORTING

    i_gjahr = '2007'

    i_periv = '24'

    IMPORTING

    e_first_day = first

    e_last_day = last.

    WRITE: / 'First Date', first, ' Last Date', last.

    Regards

    CNU

    Add a comment
    10|10000 characters needed characters exceeded

  • author's profile photo Former Member
    Former Member
    Posted on Jan 09, 2007 at 02:52 PM

    Hi,

    use this function module <b>HR_GB_TAX_YEAR_DATES</b>

    Pass these values

    P08_TXYEAR = Year

    P08_PAYROLL_AREA = '01'

    Regards

    Sudheer

    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.