Mass Absence and Attendance Upload Program
Short answer: A custom program that posts absence (infotype 2001) and attendance (infotype 2002) records coming from time clocks, shift planning tools or Excel into SAP in bulk before time evaluation. It checks the absence type, overlaps and quota sufficiency, and runs in test mode first.
- Estimated effort
- M · 4–6 working days
- System
- ECC and S/4HANA
- Tables
- 5
- Scope
- Global
- Built by
- NeKuDos Teknoloji
- Last updated
Why is the standard not enough?
PA30 and PA61 enter absences and attendances per employee; PA71 fast entry works on screen. The CATS transfer only moves data recorded in time sheets and does not cover the file layout of every external device or shift tool. Keying hundreds of records manually at month-end delays time evaluation and payroll.
Who uses it? Time management specialists, payroll teams and shift planners.
Closest standard alternatives
Tables used
The tables the program reads and updates. ECC and S/4HANA differences are marked separately.
| Table | Role | Access | System |
|---|---|---|---|
| PA2001HR Time Record: Infotype 2001 (Absences) | Absence records: absence type, date, time, duration | Write | ECC + S/4 |
| PA2002HR Time Record: Infotype 2002 (Attendances) | Attendance records: attendance type, date, time, duration | Write | ECC + S/4 |
| PA2006HR Time Record: Infotype 2006 (Absence Quotas) | Remaining entitlement for the quota check | Read | ECC + S/4 |
| T554SAttendance and Absence Types | Validity of absence and attendance types | Read | ECC + S/4 |
| PA0001HR Master Record: Infotype 0001 (Organizational Assignment) | Check of the active assignment on the record date | Read | ECC + S/4 |
BAPIs and functions used
- BAPI_EMPLOYEE_ENQUEUELock Employee. Locks the employee before posting
- BAPI_ABSENCE_CREATECreate Absence (Infotype 2001). Creates the infotype 2001 absence record
- HR_INFOTYPE_OPERATIONMaintain HR Infotype Record. Creates the infotype 2002 attendance record
- BAPI_EMPLOYEE_DEQUEUEUnlock Employee. Releases the lock after posting
Selection screen parameters
| Parameter | Description | Type | Reference field | Required | Example |
|---|---|---|---|---|---|
| P_FILE | Upload file (XLSX or CSV) | Single value | — | Yes | C:\temp\kasim_izinleri.csv |
| P_TEST | Test mode (check without posting) | Checkbox | — | No | X |
| P_QUOTA | Check quota sufficiency | Checkbox | — | No | X |
| P_SKIPOV | Skip overlapping records (do not replace) | Checkbox | — | No | X |
Input file columns
The columns of the upload template and the SAP fields they are written to. Columns with an asterisk are mandatory.
| # | Column | Target field | Required |
|---|---|---|---|
| 1 | Record type | By rule 2001 = absence, 2002 = attendance | No |
| 2 | Pers. no. | PA2001-PERNR | Yes |
| 3 | Abs./att. type | PA2001-AWART | Yes |
| 4 | Start date | PA2001-BEGDA | Yes |
| 5 | End date | PA2001-ENDDA | Yes |
| 6 | Start time | PA2002-BEGUZ | No |
| 7 | End time | PA2002-ENDUZ | No |
| 8 | Hours | PA2002-STDAZ | No |
Sample upload file
| 1 | Record type | Pers. no. * | Abs./att. type * | Start date * | End date * | Start time | End time | Hours |
|---|---|---|---|---|---|---|---|---|
| 2 | 2001 | 00001024 | 0100 | 11/23/2026 | 11/27/2026 | |||
| 3 | 2001 | 00001031 | 0100 | 11/24/2026 | 11/25/2026 | |||
| 4 | 2002 | 00001063 | 0800 | 11/18/2026 | 11/18/2026 | 09:00 | 17:00 | 8 |
Result list columns
| # | Column | Source |
|---|---|---|
| 1 | Row | Calculated Row number in the file |
| 2 | Pers. no. | PA2001-PERNR |
| 3 | Abs./att. type | PA2001-AWART |
| 4 | Status | Calculated From the checks and posting: posted, test OK or error |
| 5 | Message | Calculated Check error or BAPI return message |
Sample result list
| Row | Pers. no. | Abs./att. type | Status | Message |
|---|---|---|---|---|
| 2 | 00001024 | 0100 | Posted | Absence 23.11.2026 – 27.11.2026 posted |
| 3 | 00001031 | 0100 | Error | Insufficient quota: remaining −2 days |
| 4 | 00001063 | 0800 | Posted | Attendance 18.11.2026 09:00–17:00 posted |
How does the program work?
- The file (XLSX or CSV) is read; each row holds the record type (2001 absence or 2002 attendance), employee, absence/attendance type, date and an optional time range.
- Checks: is the employee active on the record date (PA0001), is the absence/attendance type defined for the employee’s personnel subarea grouping (T554S), is there an overlapping record on the same date (PA2001/PA2002).
- With “Quota check” selected, for absence types that deduct a quota, it is checked whether the remaining entitlement in PA2006 (ANZHL − KVERB) covers the requested duration.
- The employee is locked with BAPI_EMPLOYEE_ENQUEUE; absences are created with BAPI_ABSENCE_CREATE, attendances with HR_INFOTYPE_OPERATION; the lock is released with BAPI_EMPLOYEE_DEQUEUE. In test mode nothing is posted; only the check and simulation results are shown.
- Results are listed per row; failed rows are downloaded as a separate file. After a successful upload, time evaluation (PT60) can be run for the employees concerned.
Performance notes
Sort records by employee and date and process the rows of one employee under a single lock. Schedule month-end files as a background job before time evaluation; do not upload while time evaluation or payroll is running.
Features
- Test mode (check without posting)
- Line-by-line result and error log
- Download failed lines as a separate file Corrected rows can be uploaded again with the same template.
- Export to Excel An empty upload template can be downloaded as Excel.
- Runs as a background job Files dropped by an external system can be read by a periodic job.
Authorization objects
- P_ORGINWrite authorization for personnel data, infotypes 2001 and 2002
- P_PERNRCheck that prevents users from posting to their own personnel number
Frequently asked questions
Which external systems are supported?
The template is a fixed-column XLSX or CSV. The file layout of another device or shift tool is mapped to the template with a mapping layer during installation; each new layout adds a small effort.
What happens if there is an overlapping absence?
By default, the overlapping row is skipped and listed with a message. Optionally, an option to delimit or replace the existing record according to the collision class can be added.
Does time evaluation run automatically after the upload?
Not by default; PT60 is run separately for the employees in the result list. If needed, the program can schedule time evaluation as a background job for those employees at the end.
Packages that include this solution
Pre-Payroll Check and Upload Pack
A pack that brings together the work done before every payroll run: bulk upload of additional payments and absence and attendance records from Excel, …
Related reports
Mass Additional Payment (Infotype 0015) Upload Program
A custom program that posts bonuses, sales commissions, premiums and similar one-time payments from an Excel or CSV file to infotype 0015 in bulk. It …
Employee Leave Quota Balance and Expiry Risk Report
A custom ALV report that separates entitled, used, future-booked and remaining days in each employee's absence quota, and flags remaining leave whose …
Let us build this program for your system
Briefly describe your system and expectations. We will clarify the scope and come back with an effort and price quote.