Defining Wage Type Generation Rules

Objective

After completing this lesson, you will be able to define wage type generation rules

Time Wage Type Selection in Payroll

Flowchart illustrating wage type processing with function GWT. Planned work uses parameter 'S', while overtime uses 'M'. TIP entries feed into DZW or ZML for respective wage types with associated values and keys.

The GWT function generates time wage types for Time Pairs (TIP) table entries. These wage type entries are generated according to the rules in the Time Wage Type Selection view (V_T510S).

Following are the rules to generate the time wage types:

Time wage type selection for planned work:
TIP entries with processing type S (planned work) are processed in time wage type selection for planned time. The system checks all the TIP entries that observe the rule for each time wage type selection rule for planned working time wage types. If the rule is observed, the relevant wage type is entered in the internal table DZL.
Time wage type selection for overtime:
All TIP entries with processing type M (overtime) are processed in time wage type selection for overtime. The system checks all the TIP entries that observe the rule for each time wage type selection rule for overtime wage types. If the rule is observed, the relevant wage type is entered in the internal table ZML.

Time evaluation uses the GWT function to select time wage types for all absences that are valuated on the basis of the As If principle (the Wage Type Generation field in the Absence Valuation Rule view (V_554C_E) must be activated). This valuation is carried out for absences whose processing type has been changed to S. This is also used for absences that are evaluated using the GWT A function. All other absences are valuated in the gross part of payroll accounting.

Note

There is detailed information on absence valuation in Customizing under Payroll.

Time Wage Type Selection in Schemas

Image of two code snippets for time data processing. The first snippet checks PDC status and processes time data accordingly. The second snippet sets modifiers and selects time wage types for planned work and overtime.

If time recording has been activated for the personnel number for which the payroll is being run, it indicates that time wage types already exist in cluster B2 of table ZL. This cluster is then imported and the system processes days that have not yet been processed for the payroll period. The system still generates the wage types that are formed according to the work schedule, which triggers retroactive accounting in the subsequent payroll period.

The DAYPR function calls subschema TC00, which processes time wage type selection for planned work and overtime on a daily basis.

Time Evaluation and Payroll

Flowchart depicting the payroll process from time evaluation (June 1-20) to time wage type selection (June 21-30). Data from Cluster B2 is processed, generating Payroll Status info with the earliest MD change on June 21.

The internal tables ZL, C1, and ALP are the interfaces between time evaluation and payroll.

These internal tables contain the following information:

Table ZL:
It is the table that contains the time wage types, the number of hours per time wage type, and the amounts that are determined in the payroll.
Table C1:
It is the table that contains data relevant to cost assignments.
Table ALP:
It is the table that contains the data for different payments.

Time evaluation can only transfer the time wage types created up to this time if the payroll runs before the end of the evaluation period. For the remaining part of the payroll period, the payroll system uses the work schedule and the time management infotypes. These infotypes are available to generate time wage types for the non-evaluated interval.

When the payroll generates time wage types, it sets retroactive accounting in the Earliest Master Data Change field in the Payroll Status infotype (0003). The precondition for this is that the employee should be included in the time evaluation, that is, the value in the Time Management Status field is not 0.

Define Wage Type Generation Rules

Business Example

Until now, your company has paid overtime as employee remuneration information. However, your employees can now record attendances overtime hours in the system themselves. You want to include the time pairs recorded for overtime as time wage types in the payroll run. In the table Time Wage Type Selection Rule, you want to create different rules for each of the payroll areas in your company.

Hint

Time wage types 3##1–3##4, which were previously entered in the system as employee remuneration information, must now be generated by the system based on overtime time hours. For this reason, the Time Wage Type Selection Rule table must include rules that are grouped together in a time wage type selection rule group for each payroll area. In this exercise, you create the time wage type selection rules for the payroll area to which you assigned your employee at the time of hiring ( ## is your group number).

Use the Project IMG to create rules to define groupings and to calculate attendances overtime hours.

Task 1

Steps

  1. First, you must define the groupings. In Customizing, make a copy of personnel calculation rule TMOD, and rename it ZT## ( ## is your group number). Then, adjust personnel calculation rule ZT## by querying the payroll area in the decision operation. Set MODIF W to the value ww ( ww is ##+10 ) for your payroll area and to the value 01 for the other payroll areas. Only make this change for employees in employee subgroup grouping 3 for the personnel calculation rule.

    1. To determine the groupings for the Time Wage Type Selection Rule table, choose IMGPayrollPayroll InternationalDay Processing of Time DataDay Processing FunctionsDefine Groupings.

    2. Choose the activity Define Groupings.

      Note

      The IMG automatically calls personnel calculation rule TMOD for processing. You will need to make a copy of personnel calculation rule ZT## so that you can modify it.
    3. Select Copy, enter the following data, and choose Enter.

      FieldValue
      From RuleTMOD
      To RuleZT##
    4. Choose Change to edit your rule ZT##.

    5. In the Graphical Editor, open the following path: 3****MODIF W=03. Position the cursor on the MODIF W operation and select the Change entry icon.

    6. Overwrite the value 03 with your modifier ww (ww = ##+10, for example, group 08 has the MODIF W value = 18). Press Enter and save the change.

Task 1:

Task 2

Steps

  1. Since personnel calculation rule TMOD is accessed from subschema TC00, you must also make an adjustment here.

    Make a copy of the subschema TC00 and rename it ZC##. In the subschema ZC##, change the line with the MOD TMOD GEN function to MOD ZT## GEN. To do this, copy the line with the MOD TMOD GEN entry. Deactivate one of the MOD TMOD GEN lines and change the other line to MOD ZT## GEN.

    1. To make a copy of schema TC00 for the required modifications, choose IMGPayrollPayroll InternationalDay Processing of Time DataDay Processing FunctionsTime Wage Type SelectionPerform Time Wage Type Selection.

    2. Select Copy , enter the following data in the pop-up, and press Enter:

      FieldValue
      From SchemaTC00
      To SchemaZC##
    3. Choose Change to edit your subschema ZC##.

    4. Use the Find icon to locate function MOD on the line MOD TMOD GEN.

    5. Enter r for repeat in the column Line (Line number) of the line MOD TMOD GEN and press Enter. This creates a copy of the line.

    6. Deactivate one of the lines MOD TMOD GEN by placing an * in the D column. Press Enter.

    7. On the line that has not been deactivated, change in the column Par1 from Rule TMOD to ZT## so that your version of the rule is now active. Press Enter.

    8. Check syntax by choosing Check (F6) and then save the changes.

Task 2:

Task 3

Steps

  1. Since subschema TC00 is called up from schema XT00 , you must also make changes here. Change the relevant line in schema ZT## in which schema TC00 is accessed.

    Note

    Schema TC00 is called in two places with the DAYPR function. Time data is not processed with the time evaluation program because your company does not use time recording.
    1. To modify the payroll schema ZT##, on the SAP Easy Access screen, choose Human ResourcesPayrollInternationalToolsCustomizing ToolsPE01 - Schema.

    2. Enter your schema ZT##.

    3. Select Change.

    4. Find the line DAYPR TC00.

    5. Enter r for repeat in the column Line of the line DAYPR TC00 (not the line DAYPR TC00 PDC) and choose Enter. This creates a copy of the line.

    6. Deactivate one of the lines DAYPR TC00 by placing an * in the D column. Press Enter.

    7. On the line that has not been deactivated, change in the column Par1 from TC00 to ZC## so that your version of the subschema is now active. Press Enter.

    8. Check the syntax by choosing Check (F6) and then save the changes.

Task 3:

Task 4

Steps

  1. Enter the generation rules for the following wage types:

    Wage TypeOvertime
    3##1Overtime up to 2 hours
    3##2Overtime over 3 hours
    3##3Overtime on Sundays
    3##4Overtime on public holidays
    Set the validity period for these rules from 01.01 of the current year to 12.31.9999. According to the collective agreement for the company, public holidays and Sundays last from 00:00 to 06:00 on the following day. Incorporate these time conditions into your rules as necessary.

    1. To create generation rules for your wage types, choose IMGPayrollPayroll InternationalDay Processing of Time DataDay Processing FunctionsTime Wage Type SelectionDefine Generation Rules.

    2. Choose the Define Generation Rules activity.

    3. Enter the following four rules for selecting the time wage types (rules are numbered only to help distinguish them in these solutions).

    4. Select New Entries to access the detailed view to enter the rules.

      Rule 1: Following are the entries for wage type for first 2 hours of overtime on a working day:

      FieldValue
      Time wage type selection rule groupww (##+ 10)
      Day grouping01
      Sequence number010
      Wage type3##1
      Start date01.01. current year
      End date12.31.9999
      Valid processing typesM
      Week days1 2 3 4 5 6 7
       x x x x x x
      Public holiday class previous dayb 1 2 3 4 5 6 7 8 9
       x x x x x x x x x x
      Public holiday class current dayb 1 2 3 4 5 6 7 8 9
       x
      Public holiday class next dayb 1 2 3 4 5 6 7 8 9
       x x x x x x x x x x
      Valuation class0 1 2 3 4 5 6 7 8 9
       x x x x x x x x x x
      Daily work schedule class0 1 2 3 4 5 6 7 8 9
       x x x x x x x x x x
      Day typeb 1 2 3 4 5 6 7 8 9
       xx
      Maximum2
      Relevant processing typesM

      Press Enter and save the changes.

      Rule 2: Following are the entries for wage type for overtime after 2 hours on working days:

      FieldValue
      Time wage type selection rule groupww (##+10)
      Day grouping01
      Sequence number020
      Wage type3##2
      Start date01.01. current year
      End date12.31.9999
      Valid processing typesM
      Week days1 2 3 4 5 6 7
       x x x x x x
      Public holiday class previous dayb 1 2 3 4 5 6 7 8 9
       x x x x x x x x x x
      Public holiday class current dayb 1 2 3 4 5 6 7 8 9
       x
      Public holiday class next dayb 1 2 3 4 5 6 7 8 9
       x x x x x x x x x x
      Valuation class0 1 2 3 4 5 6 7 8 9
       x x x x x x x x x x
      Daily work schedule class0 1 2 3 4 5 6 7 8 9
       x x x x x x x x x x
      Day typeb 1 2 3 4 5 6 7 8 9
       xx
      Minimum2
      Relevant processing typesM

      Rule 3: Following are the entries for wage type for overtime on Sundays:

      FieldValue
      Time wage type selection rule groupww (##+10)
      Day grouping02
      Sequence number010
      Wage type3##3
      Start date01.01. current year
      End date12.31.9999
      Valid processing typesM
      Week days1 2 3 4 5 6 7
        x
      Public holiday class previous dayb 1 2 3 4 5 6 7 8 9
       x x x x x x x x x x
      Public holiday class current dayb 1 2 3 4 5 6 7 8 9
       x
      Public holiday class next dayb 1 2 3 4 5 6 7 8 9
       x x x x x x x x x x
      Valuation class0 1 2 3 4 5 6 7 8 9
       x x x x x x x x x x
      Daily work schedule class0 1 2 3 4 5 6 7 8 9
       x x x x x x x x x x
      Day typeb 1 2 3 4 5 6 7 8 9
       xx
      Start00:00
      End30:00

      Press Enter and save the changes.

      Rule 4: Following are the entries for wage types for overtime on public holidays:

      FieldValue
      Time wage type selection rule groupww (##+10)
      Day grouping02
      Sequence number020
      Wage type3##4
      Start date01.01. current year
      End date12.31.9999
      Valid processing typesM
      Week days1 2 3 4 5 6 7
       x x x x x x x
      Public holiday class previous dayb 1 2 3 4 5 6 7 8 9
       x x x x x x x x x x
      Public holiday class current dayb 1 2 3 4 5 6 7 8 9
        x x x x x x x x
      Public holiday class next dayb 1 2 3 4 5 6 7 8 9
       x x x x x x x x x x
      Valuation class0 1 2 3 4 5 6 7 8 9
       x x x x x x x x x x
      Daily work schedule class0 1 2 3 4 5 6 7 8 9
       x x x x x x x x x x
      Day typeb 1 2 3 4 5 6 7 8 9
       xx
      Start00:00
      End30:00

      Press Enter and save changes.

Task 4:

Task 5

Steps

  1. Test the generation rules you have created by entering Attendances Overtime Hours (infotype 2002 subtype 0801) for your employee on the following days in the payroll period 05:

    DayTime
    On a working day18:00-21:00
    On a Sunday10:00-18:00
    On a public holiday10:00-17:00

    Release payroll for period 05 and start the payroll run. Make sure you select the checkbox to display the log for time data processing. Check your result and confirm that your wage types 3##1–3##4 were generated correctly.

    Do not exit payroll for period 05.

    Note

    The derived wage types and valuation bases that you configured for the previous exercise are also used in this exercise.
    1. To test your time wage type selection rules, on the SAP Easy Access screen, choose Human ResourcesPersonnel ManagementAdministrationHR Master DataPA30 - Maintain.

    2. Enter the personnel number 400991## and choose the infotype menu tab Working times. Choose the infotype 2002 subtype 0801 Attendances Overtime Hours. Choose Create (F5) and enter dates and hours in period 05. Enter the days and hours as specified in the following table:

      Start Date / To DateTime
      On a working day18:00-21:00
      On a Sunday10:00-18:00
      On a public holiday10:00-17:00

      Press Enter and save the individual data records.

      Note

      You must create an infotype 2002 subtype 0801 record for each day that contains Overtime Hours.
    3. On the SAP Easy Access screen, choose Human ResourcesPayrollInternationalPayroll Release Payroll (for period 05).

    4. Choose Back to go to the SAP Easy Access screen, choose Human ResourcesPayrollInternationalPayrollStart Payroll.

    5. Start payroll and select your variant. Before running payroll, select the field Disp. Time Data Processing Log in the Log section. Run payroll for period 05 by choosing Execute (F8). Check whether your wage types 3##1–3##4 have been created. Review the detail display of the log section Processing of time data and open the log at the function ELSE that follows the function IF PDC.

    6. At this point, you see function DAYPR Day Processing of Time Data. Open the Processing and double-click Jump from DAYPR to detailed log. You can review the selection of wage types for each day with overtime hours within the GWT M ZML log section. Alternatively, you may also check your wage type selection result by going to the function PIT X015 GEN directly in the Processing of time data section of the log.

    7. Do not exit payroll for period 05.