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

Planned Working Time

hi all,

i got to create following program and i have no apab idea about it i had worked on functional part of sap-hr. so please help me

Create a program for checking infotype "Planned Working Time";

check if workschedule exists.

do explain me how to check workschedule existence

Add a comment
10|10000 characters needed characters exceeded

Related questions

2 Answers

  • Posted on Apr 24, 2007 at 01:36 PM

    Check for the existence of IT0007(table PA0007) field SCHKZ for the employees.

    You can use FM HR_PERSONAL_WORK_SCHEDULE also for the same.

    Regards,

    Amit

    Reward all helpful replies.

    Add a comment
    10|10000 characters needed characters exceeded

  • Posted on Apr 25, 2007 at 07:00 AM

    Hi,

    Just write this coding.

    data itab type standard table of pa0007.

    data wa type pa0007.

    CALL FUNCTION 'HR_READ_INFOTYPE'

    EXPORTING

    PERNR = '22008476' "Give employee no.

    INFTY = '0007' "Planned working time infotype

    • BEGDA = '18000101'

    • ENDDA = '99991231'

    TABLES

    INFTY_TAB = itab.

    IF SY-SUBRC = 0.

    loop at itab into wa.

    write wa-schkz.

    endloop.

    ENDIF.

    Specify the data for begda and endda if you know the date.

    Kindly reward points by clikcing the star on the left of reply,if it helps.

    Add a comment
    10|10000 characters needed characters exceeded

    • Hi,

      You need to pass the value for pernr.Make it as parameter as below and give the valid value in selection screen.

      parameters p_pernr type pa0001-pernr.

      data itab type standard table of pa0007.

      data wa type pa0007.

      if not p_pernr is initial.

      CALL FUNCTION 'HR_READ_INFOTYPE'

      EXPORTING

      PERNR = p_pernr "Give employee no.

      INFTY = '0007' "Planned working time infotype

      • BEGDA = '18000101'

      • ENDDA = '99991231'

      TABLES

      INFTY_TAB = itab.

      IF SY-SUBRC = 0.

      loop at itab into wa.

      write wa-schkz.

      endloop.

      ENDIF.

      else.

      message i000 with 'Enter pernr'.

      leave list-processing.

      endif.

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.