tbl_payelementshistory

-1 rows


Description

Module: Payroll/Compensation Management - Pay Element Configuration History Log
Purpose: Stores an immutable, historical record of all changes made to a master Pay Element definition (e.g., Basic Salary, HRA, Provident Fund deduction). This is crucial for payroll auditing and compliance.
Data: Captures the unique ID of the original pay element, and a serialized string (History) of its entire configuration object (including name, code, type, formula, etc.) at the time of the change.
Process Usage:
- Auditing: Provides a complete audit trail to track when, why, and by whom the calculation rules, names, or types of a specific pay element were changed.
- Compliance: Essential for demonstrating that the correct pay element rules were applied during past payroll runs.
- Reference: Allows retrospective analysis of pay element definitions for troubleshooting or legal review.
Key Points:
- Snapshot Storage: The History column stores the full configuration object, often in JSON format.
- Linked to the active pay element master table via PayelementId.
Business Impact: Ensures the integrity and traceability of the core building blocks of the organization’s salary structures and payroll calculations.

Columns

Column Type Size Nulls Auto Default Children Parents Comments
id bigserial 19 nextval('tbl_payelementshistory_id_seq'::regclass)

Primary key
Format: Long (auto-increment)
Used as: Unique identifier for this specific historical snapshot.

payelementid int8 19 null
tbl_employeepayelement.payelementid Implied Constraint R

FK: public.tbl_PayElements.Id (Implied)
Meaning: The ID of the master pay element whose history is being recorded.

history varchar 2147483647 null

A serialized string (e.g., JSON) representing a complete snapshot of the PayElements object and its configuration details at the time this history entry was created.

createddate timestamp 29,6 null
createdby varchar 500 null
modifieddate timestamp 29,6 null
modifiedby varchar 500 null

Indexes

Constraint Name Type Sort Column(s)
tbl_payelementshistory_pk__tbl__payelementshistory_id Primary key Asc id

Relationships