ATTENDHIST – Employee Attendance History
- System
- Time and Attendance (TM)
- Prefix
ATH- Primary key
COMPANY,DATE,ATTEND-CODE,EMPLOYEE,TIME-SEQ- Fields
- 15
- Updated by
- 9 programs
- Referenced by
- 15 programs
ATTENDHIST is the Employee Attendance History table in Lawson Time and Attendance (prefix ATH). It is indexed by COMPANY, DATE, ATTEND-CODE, EMPLOYEE, TIME-SEQ (ATHSET1); alternate indexes: ATHSET2, ATHSET3, ATHSET4 and ATHSET5. It is related 1:1 to ATTENDCODE, PRSYSTEM, DEPTCODE, EMPLOYEE and PAEMPLOYEE and 1:M to PRTIME and TAEEMASTER. It is updated by PR195, PR197, PR582, PR82.1, PR85.1, TM300, TM570, TM70.1 and 1 more and referenced by HR170, HR70.1, TM01.1, TM240, TM245, TM250, TM255, TM260 and 7 more. The table has 15 fields, 5 indexes and 8 documented relations.
About ATTENDHIST
The Attendance History file contains employee attendance history information. TM70 (Attendance History) and PR199 (Payroll Close) are the primary programs that update this file. More than one attendance record can exist for an employee for the same day. For this reason a sequence number is needed to maintain record uniqueness.
Fields (15)
Column = COBOL field name without the ATH- prefix, hyphens → underscores. Derived fields are computed by the application and are not stored.
| Field / column | Type | Description & values | Updated by |
|---|---|---|---|
ATH-COMPANY PKCOMPANY | Numeric 4 | Contains the company number. Validated in the HR Company and Process Levels file. | PR195, PR197, PR582, PR82.1, PR85.1, TM570, TM70.1, TM71.1 |
ATH-DATE PKDATE | Numeric 8 (yyyymmdd) | Contains the system date this record was created. | PR195, PR197, PR582, PR82.1, PR85.1, TM570, TM70.1, TM71.1 |
ATH-ATTEND-CODE PKATTEND_CODE | Alpha 2 | Contains the user-defined alphanumeric code that represents a reason for an employee's absence or hours worked. Examples of attendance codes are, sick, vacation, overtime, on the job injury, snow day, tardy, left early, and so on. Validated in the Attendance Code file. | PR195, PR197, PR582, PR82.1, PR85.1, TM570, TM70.1, TM71.1 |
ATH-EMPLOYEE PKEMPLOYEE | Numeric 9 | Contains the employee number associated with this attendance record. Validated in the Employee file. | PR195, PR197, PR582, PR82.1, PR85.1, TM570, TM70.1, TM71.1 |
ATH-TIME-SEQ PKTIME_SEQ | Numeric 12 | Contains the system-assigned number that makes the record unique. | PR195, PR197, PR582, PR82.1, PR85.1, TM570, TM70.1, TM71.1 |
ATH-PROCESS-LEVELPROCESS_LEVEL | Alpha 5 | Contains the process level with which this attendance record is associated. Validated in the HR Company and Process Levels file. | PR195, PR197, PR582, PR82.1, PR85.1, TM570, TM70.1, TM71.1 |
ATH-DEPARTMENTDEPARTMENT | Alpha 5 | Contains the department with which this attendance record is associated. Validated in the Department file. | PR195, PR197, PR582, PR82.1, PR85.1, TM570, TM70.1, TM71.1 |
ATH-HOURSHOURS | Signed 7.2 | Contains the hours associated with this attendance code. PR199 (Payroll Close) creates attendance history for time records with an attendance code attached. Hours is an optional entry for manual type records. | PR195, PR197, PR582, PR82.1, PR85.1, TM570, TM70.1, TM71.1 |
ATH-POINTSPOINTS | Signed 7.2 | Contains the points associated with the attendance code. The value in this field defaults from the Points field in the Attendance Code file. You can override Points in TM70 (Attendance History) if appropriate. | PR195, PR197, PR582, PR82.1, PR85.1, TM570, TM70.1, TM71.1 |
ATH-OCCURRENCEOCCURRENCE | Alpha 1 | Contains the value that indicates whether this record is a unique attendance occurrence or a continuation of a previous occurrence. For example, if an employee is sick on Monday and Thursday, this is considered two occurrences. If an employee is sick on Monday and Tuesday, Monday is considered an occurrence and Tuesday is not since it is a continuation of Mondays occurrence.
| PR195, PR197, PR582, PR82.1, PR85.1, TM570, TM70.1, TM71.1 |
ATH-RECORD-TYPERECORD_TYPE | Alpha 1 | Contains the value that identifies the record type. Attendance history records created by PR199 (Payroll Close) are system records. Records added or changed through TM70 (Attendance History) are manual records.
| PR195, PR197, PR582, PR82.1, PR85.1, TM570, TM70.1, TM71.1 |
ATH-DAYS-INDDAYS_IND | Numeric 1 | Contains the numeric value that represents the day of the week on which the occurrence took place.
| PR195, PR197, PR582, PR82.1, PR85.1, TM570, TM70.1, TM71.1 |
ATH-DATE-STAMPDATE_STAMP | Numeric 8 (yyyymmdd) | This field contains the server date (month, date, and year) of the last change to this record. | PR195, PR197, PR582, PR82.1, PR85.1, TM570, TM70.1, TM71.1 |
ATH-TIME-STAMPTIME_STAMP | Numeric 6 (hhmmss) | Contains the server time (hour, minute, and second) when the record was last changed. | PR195, PR197, PR582, PR82.1, PR85.1, TM570, TM70.1, TM71.1 |
ATH-USER-IDUSER_ID | Alpha 10 (Lower Case) | — | PR195, PR197, PR582, PR82.1, PR85.1, TM570, TM70.1, TM71.1 |
Indexes (5)
Keys marked * are descending. Every documented Lawson index is unique unless flagged Duplicates; Subset indexes carry a Where condition.
| Index | Keys | Flags | Condition | Used in |
|---|---|---|---|---|
ATHSET1 | COMPANY, DATE, ATTEND-CODE, EMPLOYEE, TIME-SEQ | Primary | TM240, TM245, TM300, TM52.1, TM570, TM70.1, TM71.1 | |
ATHSET2 | COMPANY, EMPLOYEE, DATE*, ATTEND-CODE, TIME-SEQ* | HR170, HR70.1, TM300, TM470, TM50.1, TM50.2, TM52.1, TM60.1 +3 more | ||
ATHSET3 | COMPANY, ATTEND-CODE, DATE*, EMPLOYEE, TIME-SEQ* | TM01.1, TM240, TM245, TM250, TM255, TM260, TM265, TM300 +1 more | ||
ATHSET4 | COMPANY, EMPLOYEE, ATTEND-CODE, DATE*, TIME-SEQ* | TM240, TM245, TM250, TM255, TM260, TM265, TM470, TM50.1 +1 more | ||
ATHSET5 | COMPANY, DATE*, DATE-STAMP*, ATTEND-CODE, EMPLOYEE, TIME-SEQ | KeyChange | — |
Relations
One to one (6) — lookups and parents
| Relation | Table | Rules | Condition | Field map |
|---|---|---|---|---|
| Attend Code | ATTENDCODE | Required | ATH-COMPANY → ATC-COMPANY (ATCSET1), ATH-ATTEND-CODE → ATC-ATTEND-CODE | |
| Company | PRSYSTEM | Required | ATH-COMPANY → PRS-COMPANY, Spaces → PRS-PROCESS-LEVEL | |
| Department | DEPTCODE | Required | When ATH-DEPARTMENT != Spaces | ATH-COMPANY → DPT-COMPANY, ATH-PROCESS-LEVEL → DPT-PROCESS-LEVEL, ATH-DEPARTMENT → DPT-DEPARTMENT |
| Employee | EMPLOYEE | Required | ATH-COMPANY → EMP-COMPANY, ATH-EMPLOYEE → EMP-EMPLOYEE | |
| Paemployee | PAEMPLOYEE | Required | ATH-COMPANY → PEM-COMPANY, ATH-EMPLOYEE → PEM-EMPLOYEE | |
| Process Level | PRSYSTEM | Required | When ATH-PROCESS-LEVEL != Spaces | ATH-COMPANY → PRS-COMPANY, ATH-PROCESS-LEVEL → PRS-PROCESS-LEVEL |
One to many (2) — child tables
| Relation | Table | Rules | Condition | Field map |
|---|---|---|---|---|
| Prtime | PRTIME | Valid When (ATH-RECORD-TYPE = "S") | ATH-COMPANY → PRT-COMPANY, ATH-EMPLOYEE → PRT-EMPLOYEE, ATH-DATE → PRT-TR-DATE, ATH-TIME-SEQ → PRT-TIME-SEQ, → PRT-CHECK-ID | |
| Taeemaster | TAEEMASTER | ATH-COMPANY → TEM-COMPANY, → TEM-EMPLOYEE, → TEM-PLAN, → TEM-EMPLOYEE-GROUP, → TEM-POSITION |
Programs
Updated by (9)
- PR195 Accrual Program
- PR197 Payroll Close
- PR582 Mass Adjustment Load
- PR82.1 Adjustment
- PR85.1 Bank Account Reconciliation
- TM300 Attendance History Purge
- TM570 Attendance History Conversion
- TM70.1 Employee Attendance History
- TM71.1 Attendance History Speed Entry
Referenced by (15)
- HR170 Human Resource Writer Report Request
- HR70.1 Human Resource Writer Inquiry
- TM01.1 Attendance Code
- TM240 Employee Attendance Code Report
- TM245 Employee Attendance Class Report
- TM250 Attendance Code Distribution Report
- TM255 Attendance Class Distribution Report
- TM260 Absence Monitoring Report
- TM265 Lost Time Report
- TM470 Attendance History Audit Report
- TM50.1 Employee Attendance Inquiry
- TM50.2 Employee Attendance Totals
- TM52.1 Attendance Inquiry
- TM60.1 Employee Date Calendar
- TM61.1 Employee Days Calendar