Error when deleting location codes
When deleting Payroll Location Codes the system is returning an error Error executing prlocatnio_delete The DELETE statement conflicted with the REFERENCE constraint "FK_PersonnelPosition_PayrollWorkLocation". The conflict occurred in database "xxxx"
HRM
Payroll
Location Codes
If location codes are tied to employee, position or job class or history records they cannot be deleted. This error occurs when a Location code exists in Position Control under the Position Change area.
To remove the location codes from Position Control Position Change records
Navigate to Human Resources > Position Control and Budgeting > Position Control
Click on the Position Change menu option
Click Search and enter the locations that are being deleted then click Accept
Update the records to have a different Location code and hit Accept
Navigate to Payroll> Payroll Setup > Location Codes and try to delete the impacted locations again
It is best practice once Location Codes are in the system to not delete them unless it is absolutely necessary