Wage Types, Internal Tables and Payroll Results
|
This content was generated with the assistance of AI and should be verified against the official documentation before being relied on in production. |
When a payroll run finishes, an employee has a payslip with lines such as basic salary, social contributions, income tax and the amount paid to the bank. Inside SAP, every one of those lines is a wage type: a numbered label for one kind of money amount or time quantity, together with the rules that say how the run treats it. During the run, the wage types of one employee travel through a set of working tables kept in memory, the internal tables, and at the end the system packs the outcome into the payroll result, a record stored in a cluster file. A developer or consultant who has to explain why a payslip line has a certain value, or who has to read results for a report, needs this picture of what is stored where. This page explains the two kinds of wage types, the main internal tables, the way results are saved and read, and a gross-to-net example for the employee Ana Torres of Example Trading Co. It is written against SAP S/4HANA 2025 FPS02 on premise and Private Edition, where the HR functions come from SAP HCM for SAP S/4HANA (H4S4). Everything that touches an HR database or a payroll result requires an SAP system; not run here.
Before you read
-
HR and Payroll Basics: what a payroll run, a payroll area and a payroll period are.
-
Infotypes: the master data records, such as Basic Pay, that supply the first wage types of a run.
-
HR Data Structures and Tables: the
PCL1andPCL2cluster files that hold payroll results. -
Internal tables: the ABAP concept behind the in-memory tables of a payroll run.
Key terms
-
Wage type: a numbered label for a kind of money amount or time quantity, with the rules for how payroll treats it.
-
Time wage type: a primary wage type that the system forms from time data and that carries a number of time units, usually hours.
-
Personnel calculation schema: the ordered list of steps that the payroll driver executes.
-
Personnel calculation rule: a small decision tree of operations that changes the entries of the internal tables.
-
Payroll result: the outcome of a run for one employee and one period, stored in a cluster of file
PCL2. -
Cluster: a group of fields and internal tables that the system stores as one record and reads back as a whole.
-
Net pay: the amount left after the deductions, before any deductions taken from the net amount.
The running example: Example Trading Co.
All HR pages on this site use one fictitious business, Example Trading Co. Every key, name, number and date is an invented
example value, not a value delivered by SAP; in particular the wage type numbers 1000, 2000, 3000, 3100 and 3500
below are made up for this page, and a real system defines its own. Dates are written DD.MM.YYYY, as an SAP screen shows
them.
-
Payroll area
E1"Monthly EX01" (monthly period, 01.MM to the last day of MM), company codeEX01. -
00001234Ana Torres, Sales Manager, hired 01.03.2024, employee subgroupAA, basic pay 4,000.00 EUR a month. She is the featured employee. -
00001236Chloe Martin, Warehouse Clerk, employee subgroupAB, paid 14.00 EUR an hour. It is this example’s choice that her hours are paid in the monthly payroll areaE1. -
The payslip of Ana for March 2026 uses flat example rates that are not the rules of any country: gross 4,000.00; employee social contributions 20.00% = 800.00; income tax 15.00% of (4,000.00 - 800.00) = 3,200.00 x 15% = 480.00; net 2,720.00. Employer contributions 21.00% of gross = 840.00, so the employer cost is 4,840.00. The arithmetic was checked by hand and with a small script; it was not produced by a payroll run.
What a wage type is
Help defines wage types as the objects that separate money amounts or time units that are used in different ways to calculate the remuneration. The standard examples are that Standard Pay differs from Union Dues, and that the Overtime wage type is processed differently from the Monthly Salary wage type. A wage type carries three value fields:
| Field | Meaning | In the example |
|---|---|---|
|
Amount. For a standard pay wage type, the amount the employee should receive. |
Ana: 4,000.00 on the wage type for her monthly salary. |
|
Rate. The valuation basis, for an hourly wage type the hourly rate. |
Chloe: 14.00. |
|
Number. For a time wage type the number of time units, such as hours, that the run multiplies by the valuation basis. |
Chloe: 176.00 hours (an assumption: March 2026 has 22 weekdays of 8 paid hours, public holidays ignored). |
Depending on the wage type, one field or several are filled. For Chloe the run computes . Besides the fields, each wage type has characteristics. Some control how it is entered on screen: whether it can be entered in an infotype, whether it counts as a payment or a deduction, whether its value is direct or comes from a valuation, and rounding. Others control how it is processed: the processing class and the evaluation class, the cumulation wage types and the bases for averages and valuation that it belongs to. Similar wage types are grouped in wage type groups.
Primary and secondary wage types
Help divides wage types into two categories by how they come into existence.
-
A primary wage type exists before the run starts. A dialog wage type is entered in master data, for example the salary in Basic Pay (infotype 0008). A time wage type is formed from time information, or entered online. A time wage type is written to payroll only with a number, usually of hours, and is valued during the run.
-
A secondary wage type is technical and is generated by the system during the run. Its name always starts with the slash character
/, for example/001. Secondary wage types also cumulate several wage types or store interim results.
Help gives one standard example: the secondary wage type /101 (Total Gross Amount) is created in the run and cumulates
all the wage types that belong to the total gross amount. Another one named in the posting documentation is /559 (Bank
Transfer). This is the difference between the wage types you see in a master data screen and the technical ones you
only see in a payroll log or a result: the first are entered by people, the second are produced by the rules.
Model wage types and the customer wage type catalog
SAP delivers a wage type catalog of model wage types, already configured for payroll. The documentation says to generate
your own wage types by copying the model wage types into the customer name range and then modifying the copies, and to
use only customer-specific wage types in live payroll. The copies live in names that start with a digit, which is why the
wage types of Example Trading Co. in this page are written 1000, 3000 and so on. You can copy a whole wage type group
or copy one model wage type as a prototype and duplicate it. The wage type copier is the tool, and the Customizing path
of the wage type catalog is documented in the Payroll Customizing under Basic Settings, Environment of Wage Type
Maintenance. The report RPDLGA20 ("Use of Wage Types in Payroll") lists, for a country, the wage types and their
characteristics. Running them requires an SAP system; not run here.
| Kind | Example in this page | Where it comes from |
|---|---|---|
Model wage type |
Not used directly in live payroll |
Delivered in the SAP wage type catalog, copied to the customer name range. |
Customer dialog wage type |
|
Entered in Basic Pay for Ana. |
Customer time wage type |
|
Formed from Chloe’s time data and valued with her rate. |
Customer deduction wage types |
|
Calculated by rules in the run. |
Secondary wage type |
|
Generated by the system; names from the SAP Help documentation. |
Internal tables during a payroll run
The payroll driver runs the personnel calculation schema, a sequence of functions. The functions read and change data in internal tables that the system fills and queries during the run; read and change access happens through functions in the schema and through operations in personnel calculation rules. The table lists the ones the documentation names as used in all country versions, in the wording of the task of each.
| Table | Name in Help | Role |
|---|---|---|
|
Work Place/Basic Pay |
Filled from infotypes Actions (0000), Organizational Assignment (0001), Planned Working Time (0007), Basic Pay (0008) and Cost Distribution (0027). Holds organizational and payment-relevant data and the partial period parameters. |
|
Input Table |
Filled with the data to be processed, for example Chloe’s hours. Data goes from |
|
Results Table |
The result wage types of the current period. This is where Ana’s gross, deductions and payment end up. |
|
Cumulative Results Table |
Cumulations of the wage types of |
|
Payment Information |
One entry per payment made to the employee in a payroll period. |
|
Cost Distribution |
Global cost distribution information per wage type; certain costs can go to cost centers other than the master cost center (from infotype 0027). |
|
Cost Assignment from Different Infotypes |
Individual cost assignment per wage type, for example from Recurring Payments/Deductions (0014) and Additional Payments (0015). |
|
Old Results Table |
The table |
Help says other tables exist, such as V0, GRT, ARRRS, DDNTK, ACCR, BENTAB, FUND, AVERAGE, MODIF,
VERSION, PCL2, VERSC and STATUS, and that other internal tables apply only to some country versions. Some tables
are exported at the end of the run into the cluster; others, such as IT, OT, DT, ORT, LRT and VORT, are
deleted afterward because they are needed only during the run. Because the next run needs earlier results, the system
imports a previous result with the function IMPRT and moves its tables to "old" tables such as ORT, OCRT and
OARRRS, which are deleted after the run. In a payroll log you can see what a given table contains at a given point.
The path of a wage type through one run
The diagram follows Ana in March 2026. It simplifies: real schemas have many more steps, and the Help page on the
payroll schema shows the main steps of international schema X000 as, among others, initialization, editing basic data,
importing the previous result, gross remuneration from time management, factoring, an iteration with processing of
deductions, retroactive accounting, and net payments and deductions with transfer.
From gross to net: the arithmetic
The conceptual model used on this page, a teaching simplification and not a quotation from SAP, has four quantities. Statutory deductions are the deductions the law requires, here the social contributions and the income tax. Other deductions taken while the net amount is still being formed are . Deductions taken from the net amount afterward, such as repaying an advance, are . Then:
Help describes the same order in words: the system calculates the gross wage, the partial period factors, lump sums and salary elements and cumulates the gross results, then calculates the net remuneration, and the schema of the example page has a step for net payments and deductions. For Ana in March 2026 with the generic flat rates:
| Line | Wage type (invented unless noted) | Amount in EUR |
|---|---|---|
Basic salary |
|
4,000.00 |
Total gross |
|
4,000.00 |
Employee social contributions, 20.00% of 4,000.00 |
|
800.00 |
Income tax, 15.00% of (4,000.00 - 800.00) = 15.00% of 3,200.00 |
|
480.00 |
Net: |
none |
2,720.00 |
Payment, no deductions after net: |
|
2,720.00 |
Employer contributions, 21.00% of 4,000.00 (not on the payslip) |
|
840.00 |
The employer cost is . If Ana had a deduction after net of 100.00, an invented variation not in her payslip, the net would stay 2,720.00 and the payment would be . The rates are generic and are not any country’s real rules; real tax and social security calculations depend on the country version of payroll.
Where the result is stored: PCL2, the cluster key and RGDIR
At the end of the run the system exports the tables into cluster tables in PCL2. The documentation says PCL1 holds
primary information, such as master data and time recording data, and PCL2 the secondary information: derived data, the
payroll results and the generated schemas. The payroll result sits in a country-specific cluster, called Rx in Help
with x the country, for example RD for Germany. The data of a cluster are stored with the cluster name in the field
RELID and the key in the field SRTFD, 40 bytes of which are available for the key. For the payroll cluster the key
contains the personnel number (PERNR) and a sequential number (SEQNO), both in the structure PC200.
Because the key is a number with no meaning, you first find the right result. The internal table RGDIR (the payroll
directory, defined from the structure PC261) has one entry per payroll result, each with a sequential number, and the
documentation says to select the entry first, for example by the for-period, in-period or payroll area, and then import
the result with that sequential number. For Ana, the March 2026 result is one entry of RGDIR; if retroactive accounting
changes it later, there is a further entry, and the original one stays in the directory.
Reading results
Help states that data in a PCLn file is imported with the macros RP-IMP-Cn-xx, and exported with the macros
RP-EXP-Cn-xx, and that only these macros, or the function module named below, should be used. For the payroll results it names the function module
PYXX_READ_PAYROLL_RESULTS as the other supported way. The macros use the ABAP statement IMPORT with the database
PCL2, check the buffer first, and run a check for cluster authorization. The parameters of the function module are not
reproduced on this page: read them in the documentation of the function module in your system, which is in-system
documentation. The function modules whose names begin with CD_ select entries from RGDIR. The listing is adapted from the
sample report in the Help page "Sample Report", with Ana’s personnel number and period. The value '02' of
INPER_MODIF is taken over from the sample, and is explained in the function module documentation.
Requires an SAP system; not run here.
REPORT zexp_read_rgdir.
DATA: rgdir LIKE pc261 OCCURS 0 WITH HEADER LINE,
evpdir LIKE rgdir OCCURS 0 WITH HEADER LINE.
INCLUDE rpcccd09.
CALL FUNCTION 'CU_READ_RGDIR'
EXPORTING
persnr = '00001234'
TABLES
in_rgdir = rgdir
EXCEPTIONS
no_record_found = 1
OTHERS = 2.
CALL FUNCTION 'CD_EVALUATION_PERIODS'
EXPORTING
bonus_date = '00000000'
inper_modif = '02'
inper = '202603'
pay_type = cd_c-regular
pay_ident = ' '
TABLES
rgdir = rgdir
evpdir = evpdir
EXCEPTIONS
no_record_found = 1
OTHERS = 2.
Source: Sample Report (SAP Help Portal, Human Resources). The program name is invented. With evpdir filled, a program would import the result for each entry through the import macro of the cluster. The classes and function modules of newer, object-oriented access are not named here because no official page confirmed them.
What older books show, and what has changed
The book SAP ERP HCM: Technical Principles and Programming, 1st edition (2013), by Dirk Liepold and Steve Ritter,
describes the same internal tables (WPBP, RT, BT, CRT, TCRT), the payroll directory RGDIR of structure PC261,
and the import macros such as RP-IMP-C2-RU, using the US payroll as its main example. Several things differ today.
-
The book is written for SAP ERP HCM. From SAP S/4HANA 2025 the Business Function for SAP HCM for SAP S/4HANA is active by default and compatibility mode is no longer possible, and HCM for S/4HANA needs a separate license. The tables and macros above still exist in the documentation of the 2025 FPS02 release, but a project on H4S4 must verify them in its own system.
-
The book shows the US country version in detail. Other countries have their own result structures and reports, and the Help documentation lists them in the country versions.
-
The book’s listings use header lines and
OCCURS, the old table style that new ABAP code does not use; see Internal Tables. -
Employee Central Payroll in SAP SuccessFactors is a cloud option for running payroll, and its documentation is separate from the on-premise pages cited here; this page does not describe it.
-
The publisher page cited below lists the 2nd edition, which is not the edition read for this page.
Summary
-
A wage type is a numbered label for a money amount or time quantity, with fields
AMT,RTEandNUMand characteristics that control entry and processing. -
Primary wage types exist before the run (dialog wage types from infotypes, time wage types from time data); secondary wage types such as
/101are generated in the run and start with/. -
Model wage types are copied to the customer name range, and only customer wage types are used in live payroll.
-
During the run the data moves through internal tables:
ITin,RTout, withWPBP,CRT,BT,C0andC1beside them, and the old results arrive inORT. -
The result is exported to a country cluster of
PCL2;RGDIRlists the results of an employee, and the supported ways to read them are theRP-IMP-C2-xxmacros andPYXX_READ_PAYROLL_RESULTS. -
For Ana in March 2026 the flat example numbers give gross 4,000.00, net 2,720.00 and payment 2,720.00, with an employer cost of 4,840.00.
Try it
To do this by hand, follow the guide Compute Pay for a Partial Period and Gross-to-Net: it computes pay for a partial period and a gross-to-net payslip.
References
-
SAP ERP HCM: Technical Principles and Programming (publisher page; it lists the 2nd edition)