tbl_employeerelationhistory

-1 rows


Description

Module: Employee Profile
Purpose: Stores the history of employee relations added or updated by employees.
Data: Each record represents a submitted or modified relation entry (e.g., family member) of the employee.
Process Usage:
- Employees add or update their relation details (family, dependents, etc.).
- HR reviews and approves/rejects the entry.
- Approved records are reflected in tbl_employeerelation (main table).
Key Points:
- Captures details like name, relationship type, occupation, and contact number.
- Provides historical traceability for all relation updates.
Business Impact: Ensures accurate and verified record-keeping of employee dependents and emergency contacts for HR and compliance purposes.

Columns

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

Primary key
Format: BIGSERIAL (auto-increment)
Usage: Unique identifier for each relation history record.

erelationid int8 19 null
tbl_employeerelation.erelationid fk__tbl_emplo__erela__3b0a5e28 R

Meaning: Reference to main relation record.
Foreign Key: tbl_employeerelation.erelationid
Usage: Links this history record to its corresponding entry in the main relation table.

employeeid varchar 20 null
tbl_employee_previous_pf.employeeid Implied Constraint R

Meaning: Employee identifier.
Format: VARCHAR(20)
Usage: Indicates which employee this relation belongs to.

ertype varchar 40 null

Meaning: Type of relation.
Format: VARCHAR(40)
Examples: Father, Mother, Spouse, Child, etc.
Usage: Defines the relationship between the employee and the related person.

ername varchar 60 null

Meaning: Name of the related person.
Format: VARCHAR(60)
Usage: Stores the full name of the family member or dependent.

eroccupation varchar 100 null

Meaning: Occupation of the related person.
Format: VARCHAR(100)
Usage: Captures the profession or employment details of the related person.

erbirthdate timestamp 29,6 null

Meaning: Birth date of the related person.
Format: TIMESTAMP
Usage: Used for record-keeping and validation of dependents (e.g., for benefits eligibility).

erdiscription varchar 100 null

Meaning: Description or remarks about the related person.
Format: VARCHAR(100)
Usage: Optional field for additional notes.

ermobileno varchar 15 null

Meaning: Mobile number of the related person.
Format: VARCHAR(15)
Usage: Used for emergency contact or communication details.

status varchar 20 null

Meaning: Approval status.
Format: VARCHAR(20)
Possible Values: Pending, Approved, Rejected
Usage: Indicates the workflow state of the relation entry.
Behavior: When Approved, data is reflected in tbl_employeerelation (main table).

rejectreason varchar 200 null

Meaning: Remarks for rejection.
Format: VARCHAR(200)
Usage: Captures HR comments when rejecting a record.

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

Relationships