ABAP-HR Monthly work schedule issue

Dear experts,
I am fetching the leaves taken by employees from IT 2001.
But there, only the number of leaves granted ina period are given, not the days on which was granted.
e.g. say for an employee 40030089, there are 8 sick leaves in the period- 01.03.2009 to 10.03.2009(11 days). That means for rest three days there is either Weekly off, holiday or other absence.. Now how do I know which day amongst these was a  holiday or Weekly off ... and on which day the leave was granted?
I am doing it using tables PA0001,PA0007 and T552A(monthly work schedule) which seems to be very complex. I am afraid I might be missing something. Is there any standard table, FM, that could tell what was the status for that employee on that particular day(Holi, WO, other absence)?
Regards,
Sumit Nene

Hi,
You use fuction module to get leave in
               WHILE i_pa2001-begda <= date.
                SELECT SINGLE mofid FROM t001p INTO calid WHERE werks = wa_final-werks.
                  CALL FUNCTION 'HOLIDAY_CHECK_AND_GET_INFO'
                    EXPORTING
                      date                    = i_pa2001-begda
                      holiday_calendar_id     = calid
                      with_holiday_attributes = 'X'
                    IMPORTING
                      holiday_found           = lc_holiday_found
                    TABLES
                      holiday_attributes      = ltab_holiday_attributes.
                  CALL FUNCTION 'DAY_IN_WEEK'
                    EXPORTING
                      datum = i_pa2001-begda
                    IMPORTING
                      wotnr = day.
                  IF lc_holiday_found = 'X' OR day = 7.
                  ELSE.
                    sum_d = sum_d + 1.
                  ENDIF.
                  i_pa2001-begda = i_pa2001-begda + 1.
                ENDWHILE.
Above logic give you better  idea about how to used function module and function module name
Rgds
Ravi Lanjewar

Similar Messages

  • Fastest way to enter multiple events (monthly work schedule)?

    I have a question that has been driving me mad. I am wondering what is the fastest ways to enter multple events into iCal.
    Every month, my wife gets her work schedule which is composed of various shifts throughout the week. What I would like to do, ideally, would be to set up an excel spreadsheet with a few variables (time on, time off, date, etc) and then have automator take all of that info and create the months worth of events in iCal.
    I am sick of having to click and drag each event and work through 20+ events each month because it simply takes too long. iCal must have an easy way to do this that I am unaware of. Any help?

    Happy first post! (unless you have been posting for ages and the new system has lost your record
    My teaching schedule changes from time to time. I keep a copy of it in a text file. When it changes, I edit the text file then run an applescript which removes all entries in iCal calendar timetable, then uses the text file to make a new set of entries. I use a text file because it is also the html file that I use to post a copy on my web server, but the script could fairly easily be modified to pull the data from a spreadsheet. You are welcome to have a copy to play around with.
    How does your wife's new schedule arrive? If it is by email, then you could consider having the email fire off the script, and pull the data directly from the mail.
    AK

  • ABAP Program back ground scheduling issue.

    Hi experts,
    I am trying to execute a ABAP program in a process chain but the job log shows me the following message
    "Object XXXXXXX of class RE and language PT not exist"
    XXXXX is the ABAP program name.
    Even i tryed to excute the ABAP program itself in backgroud , but i am getting the same problem.
    What´s the reason and how to solve this issue.
    Message no. SF616
    Best Regards,
    Ramesh

    Hi all,
        following the complete message i was getting.
    Object ZSALES_BACKUP of class RE and language EN does not exist.
    Message no. SF616
    Diagnosis
    The specified documentation element is not in the system.
    Procedure
    Check that your entry is written correctly.
    Regards,
    Ramesh.

  • Define Work Schedule Rule when Period Work Schedules are created

    Experts:
    I am trying to configure a DWS and PWS for a given plant.  I am aware from a different network thread that this is a 11 step process.  I have created the following:
    PSG= 03
    DWS = 1
    Breaks were defined
    Created DWS of 1stI, 2ndI, and WNDI  (ist shift, 2nd shift, and weekend shift)
    Verified day types are correct
    Created the following period work schedules:
         WK     1     2     3     4     5     6     7
    1STI     1     1STI     1STI     1STI     1STI     1STI     FREI     FREI
    1STI     2     1STI     1STI     1STI     1STI     1STI     FREI     FREI
    1STI     3     1STI     1STI     1STI     1STI     1STI     FREI     FREI
    1STI     4     1STI     1STI     1STI     1STI     1STI     FREI     FREI
    2NDI     1     2NDI     2NDI     2NDI     2NDI     FREI     FREI     FREI
    2NDI     2     2NDI     2NDI     2NDI     2NDI     FREI     FREI     FREI
    2NDI     3     2NDI     2NDI     2NDI     2NDI     FREI     FREI     FREI
    2NDI     4     2NDI     2NDI     2NDI     2NDI     FREI     FREI     FREI
    WKDI     1     FREI     FREI     FREI     FREI     WNDI     WNDI     WNDI
    WKDI     2     FREI     FREI     FREI     FREI     WNDI     WNDI     WNDI
    WKDI     3     FREI     FREI     FREI     FREI     WNDI     WNDI     WNDI
    WKDI     4     FREI     FREI     FREI     FREI     WNDI     WNDI     WNDI
    How do I define the rules to determine variant for monthly work schedule rule generation??
    I am aware that X stands for that it is relevant to the calendar and that 1 = Monday - 7 = Sunday.
    Can someone help  define the work schedule rules I need and what each code means??
    Thanks,
    Bobbie

    Hi Bobbie,
    1 . By Using variants you can make changes in normal working timings.....and these changes made in Table         V_T550X...conditions can be applied by using
             .........  Holiday Class
             .........  Holiday Class for the next day
             .........  Weekday
             .........   Variant
    Holiday Classes :
    Blank stands for -
    Not a public Holiday
    1 stands for        -
    Public Holiday
    2 Stands for       -
    Half day Holiday
    3-9 stands for    -
    Customer specific Public holiday Classes
    Variants of daily work schedule Selection rule 01 stands for :
       --- Standard variant  Blank
       --- variants A for work on Fridays
    Variants of daily work schedule Selection rule 01 stands for :
       --- Standard variant Blank
       --- Variant A Work on Friday
       --- Variant B work on Public Holidays of Public Holiday Class 2
       --- Variant C work on days preceding Public Holiday Class 4
    For ex: if ur company wants to treat second week of  Saturday is half day holiday for employees..then u can do this by fulfilling the fallowing conditions..
                ...  Select holiday class 2  in Holiday Class field by putting X
                ...   Holiday Class for the next day select each holiday class
                ---  Weekday - select workday as Saturday (6)
    ......finally create daily work schedule and attach the daily work schedule variant  to Daily work schedule (V- T550X to V-T550A)..then u assign ur daily work schedule to period work schedule,period work schedule to work schedule....
    .......You can configure these  rules for any type of weekdays or weekends ...its depends on the requirement of client to client
    ........X represent applicability of holiday class in Holiday class and Holiday class next day & weekday...
    2 . Come to selection rule.....In selection rule u can treat ur holiday class by using day type...ex ....if u want ur managerial category people won't get paid if they work on public holidays or Sunday...u can do this by using selection rules...
    3 .  Personnel Time Management :
            --- Work Schedules
                            --- Define Public Holiday Class
    Personnel sub area grouping for the work schedules and daily work schedule
      daily work schedule  .... Break schedule , Define rules for variants & daily work schedule
    Define Period work schedule
    Day types - Define day types,selection rules & Special days
    Work schedule rules and work schedule
               .... Define employee sub group grouping  and  groupings for public holiday classes
               ....  Set work schedule rules and work schedules           
               .... Generate work schedules
    Please take care of the grouping...
    i think now u could the understand the concept now ....
    Thanks & Regards,
    Avanthika.k

  • ? system considers 1 day before and 1 day after in generating work schedule

    Dear team:
    Why the system considers a day before and a day after while generating the personal work schedule. Is their any specific reason behind this, please let me know.
    Also experts say that a month work schedule to be generated in advance before the go-live date.
    Regards
    Mallikarjun P

    Hi Advait,
    Check IT 2003 ( substitutions ) infotype in the date range around the public holiday.
    It may so happen that there is a substitution.
    cheers,
    Ajay

  • Change/ removal of Unit of Issue in Material master Work scheduling view

    Hi,
    Is there a way to remove Unit of Issue from Work scheduling view? it is giving error message as "this is being used in BOM". Even if we put deletion indicator also it is showing same error message.
    Regards,
    R. Srinivasan

    Do a CS15 for the material in question and make sure you go in the BOM and select the material and click on delete/remove you can then do this.
    I have tested it and it works.
    Regards
    Adeel

  • Issue: PSG grouping for Work schedule

    Hi ,
    I want to create a work schedule with PSG grouping for workschedule as 70, I have tried to copy an existing-  none are available under the same grouping.
    I have tried using the create button though is creates a dws with grouping as 00, which shows as a non editable field.
    please advise on the issue
    Thanks and Regards,
    Prakash

    Hi,
    you want to create a workk schedule with grouping 70 ?
    then why are you copying the existing one where you can give all the entries by going new entries.... and do it..
    regards,
    mohammed

  • Work schedule: Approval field for a position - How to get it in ABAP?

    Hi all,
    could you please help me to find out how to get in a ABAP report the value of field Approval
    (RHCSHORA-CPROZT) that is shown in the Work Schedule tab in OM (PPOSE tx), starting
    from a position id? E.g. 100,00 (% of Standard value)
    Thanks in advance, bye.
    Angelo

    Hi,
    Are you asking about staffing Percentage?
    Check Table HRP1001 with relation ship A008 .
    get Weighting Percentage.
    Regards,
    Manoj.

  • Issue with respect to Daily work schedule creation for employees in UK Shif

    Hi Experts,
    We are implementing neagtive time management for our client . there are a set of employees who work in UK shift.
    Th shift timings are a bit odd.
    Timings 11:30  to 18:00 is the time when employee has to work at his Office
    and  21:00 to 22:00  he has to work from home
    Please make a note the above given timings is for a single day.
    Please guide me how to go a head.
    Regards,
    Smitha

    Smitha
    Create break schedules as below first
    01     UKBK     01     18:00     18:30               0,50
    01     UKBK     02     18:30     22:00     2,50         
    then create daily work schedule as below
    DWS grouping         01                                       Start         End
    Daily work schedule  UKDW   UK daily Work       01.01.1990 31.12.9999
    Planned working hours               DWS selection rule          01
    Planned working time            -
    Planned working time     11:30  -  22:00
    Normal working time             -
    Core time 1                     -
    Core time 2                     -
    Work break schedule      UKBK
    Hope it will solve your problem.
    Surya

  • Issue in Work Schedule

    When I am going for new entries in node 'Set Work Schedule Rules and Work Schedules' I am getting the wrong default value for DWS grouping. The value is greyd out and I can't change that. Can someone please suggest why its happening  and how can I correct that...
    Regards,
    Mukesh

    Hi Mukesh,
    Always copy the existing entries and do the editing, for example if your DWS grouping is 40, copy 40 entry and edit it and finally save it.
    If u going with new entries enter the values in the following fields:-
    ES grouping
    Holiday Calendar ID
    PS grouping
    Ref. date for PWS
    Start point in PWS
    Rule for day types
    and now press enter. your grouping will pop up automatically.
    Hope it helped you.
    Regards,
    SAPUUSER

  • Holiday not reflecting in Period Work Schedule of employees

    Hi friends
    I have a serious issue here.  I have created  a Floating public holiday and assigned to my Holiday calendar which comes on 23rd of May.  When I regenerated the Work schedule rule, it is reflecting showing holiday class as 01 and day type as 01.  But when I generated Period work schedule for all employees  for the month of May, 23rd May is not reflecting as holiday class 01 and day type 01, instead it is showing as work/paid.
    Could anyone please help how to resolve this issue.
    Regards

    Hmm, time evaluation is not a prerequisite for use of substitutions. It is also used in payroll (daily processing) too.
    So, if you see you WSR in IT0007 as it is required, then your work schedule is correctly generated. No worries. But when you don't see it in this report then the reason can be substitution or report logic or any other impact (I don't know yet).
    Can you check what you see in IT 2051 - it has consolidated view. There you immidiately see any addiotnal time data (attendances, abcenses, substitutions).

  • Query on Period Work Schedule

    In my project, some employees have weekly OFF on 1st & 3rd Saturdays, but no OFF on 5th Saturday (if the month happens to have 5 Saturdays). However, all the Sundays are OFF days. How do I set up the Period Work Schedules for this case? Kindly help me.
    -Kalpana

    hi kalpana,
    Your issue is same as mine, i have rectified it with creating 12 2nd Saturday holidays and 12 3rd Saturday holidays and rest of the saturday are working.
    Create holiday with a fixed day from date. in the next screen you will get all the week days select the radio button on saturday
    and at the earliest tab at day field give 8 and month as 1 , where 8 will be the second saturday and  month 1 will be january,
    and in the same way give 15 in day field and month as 1, where 15 will be the third saturday and month 1 will be january.
    In the same way create for rest of the months. and create work schedule it will solve your issue permanently.
    Regards
    Manoj K

  • Work schedule display in capacity leveling cm25

    Hello,
    In our company we have created a work schedule (tcode OP4A) and have associated to a work center (tcode IR02).
    However, capacity leveling (tcode CM25) doesn't display the work schedule associated to our workers in the graphical planning table.
    Do you have any idea how to solve this problem?
    Thank you very much,
    Óscar

    It could be issue with your over all profile..
    Use - Over all profile SAPPM_G001  
    Overall prof: SAPPM_G001           PM: Ind.cap/tab/day/avail.lab./norm.schd
           Select.profile:                     SAPPM_S001      PM: Tab/work center/lab/
           Control profile:                    SAPPM_C004      PM: Capacity planning table individual
           Time prof:                          SAPPM_Z0T1      PM: Tab. short-term (1 month)
           Evaluation prof.:                   SAPPM_A001      PM: Plant maintenance
           Strategy prof.:                     SAPPM_T002      Lead time sched. backwards
           Capacity planning table (tab.form): SAPPM_R001      PM: Plant maintenance/Individual caps.
    Note: Don't modify the Standard profile .

  • Time Management - Work Schedule /Absence Quota / Part-time quota generation

    Hi Experts,
    Need your help!
    We have a requirement where we need to create distinct work schedules for each irregular / part-time work pattern and the number of work patterns we have identified is more than 1000.  We are using report RPTQTA00 to generate quota. We have used work contract, employee sub-group & employee payscale group in the QUOMO feature to get the base entitlement picked up. We have defined base entitlement for the full time workschedules with 37.0 / 38.5 hours and there is a reduction rule which reduce the absence entitlement for part time employees as per the employement percentage in IT0007. Now we have a scenario where we have created a work schedule with different no of hours for each day of week (M-4, T-6, W-4, TH-6, F-4, S-OFF, SU - OFF); this work schedule is treated as full time work pattern by the system and quota is generated as full time work schedule refering to the QUOMO settings, but as per my client employees with this work schedule have reduced hours of working hours (24 hours, not 37.0 or 38.5 hours)and hence it should be treated as part-time employees, and the quota generated should be proportionately reduced. I have very limited scope to create any ESG or PSG as we do not have any distinct emplyee sub-groups maintained for full-time and part-time employees and the project has already gone-live with payroll/time. It is worth mentioning over here that we are recording absence through ESS and it takes into account the daily planned working time maintained in IT0007, so we are very particular to keep it as accurate as possible.
    I would really appreciate if somebody can please suggest any possible solution for the above issue, or guide me on what would be the best way to tackle it. I can give more details in case anybody need to have a better understanding of the issue to suggest a solution.
    Thanks in advance
    Sujit

    Hi Kathy,
    Yes, i have found the solution to it. I do not know whether it will fit into your situation or not, but i got two solutions for my issue mentioned above, please check it may help:
    1) To use capacity utilization field in IT0008 to get the FTE hours and defining the reduction rule of absence quota based on the capacity utilazation percentage.
    2) There are three user exits available in the standard report RPTQTA00, i have used one of them to write my own rules for the calculations (deduction rule)
    Do let me know if i can help you in any respect. Thanks.
    Regards,
    Sujit

  • Report to check work schedule - If case more than hundreds of work schedule

    dear experts,
    I have one issue to create work schedule for the next year. I want to create(pt01) active work schedule for the next year(2012).
    However i have issue because I don't remember which work schedule still active.This is because we have hundreds
    of work schedule rule based on emp sub group grouping, holiday calendar,psa grouping and w schedule rule.
    Is there any reports to check all the active work schedule .I'm afreaid ihave missing certain  work schedule for next year...

    If you use the IMG node for automatic generation of Work Schedule Rules
    (Time Management > Work Schedules > Work Schedule Rules and Work Schedules > Generate Work Schedules in Batch)
    you can generate all work schedules associated to a Holiday Calendar
    and only the active work schedules will be generated.

Maybe you are looking for

  • Video Output to NTSC monitor

    I recently got new furniture, so of course, I unhooked everything and moved it around, and now, for some reason, I can't see video on my NTSC monitor. I know everything is hooked up correctly because I can log and capture and see video on the monitor

  • Overclock RAM on MSI Z97 Gaming 9 AC

    Corsair 2 x 4GB CMD8GX3M2A1600C8 Now I run the ram at 2133MHz With Memory try it in Bios. (performance mode) and game like FIFA 15 running smooth. controller more responsive. but after play 20 minute back to delay controller.but after play 20 minute

  • J1INMIS : Correct amount not picked while challn printing

    Dear Gurus, I am facing problem while running tcode J1INMIS for Challan Update Status. When I am running the transaction system is showing INR 178 amount against WHT tax code CC . which I can see in the accounting document also. but while updating ch

  • OIM - Self Registration and Virtual Recognition

    Does anyone know if it's possible to integrate visual recognition (type in what you see) when a user is creating a self registration request? If possible, what is the level of effort?

  • Electrochoc : la prochaine suite d'Adobe en location obligatoire !!!

    Bonjour, J'étais un heureux client et utilisateur des outis Adobe depuis de nombreuses années. Comme pour beaucoup d'entre nous, ces outils sont devenus indispensables et il est difficielement imaginable de s'en passer ou basculer sur une inexistante