You are on page 1of 1

The relationships between these tables are as follows:

The department table has a one-to-many relationship with the position table, as each
department can have multiple positions but each position can only belong to one
department.

The position table has a one-to-many relationship with the employee table, as each
position can have multiple employees but each employee can only have one position.

The employee table has a one-to-many relationship with


the employee_allowances table and the employee_deductions table, as each employee
can have multiple allowances and deductions but each allowance and deduction can
only belong to one employee.

The employee_allowances table and the employee_deductions table both have a


many-to-one relationship with the allowances table and the deductions table,
respectively, as each employee allowance or deduction can only belong to one
allowance or deduction type, but each allowance or deduction type can be associated
with multiple employee allowances or deductions.

The payroll table has a one-to-many relationship with the payroll_items table, as
each payroll run can have multiple payroll items but each payroll item can only
belong to one payroll run.

The payroll_items table has a many-to-one relationship with the employee table, as
each payroll item can only belong to one employee but each employee can have
multiple payroll items.

You might also like