Skip to main content

Error creating pay history record: Violation of UNIQUE KEY constraint 'IX_Pay History'

Error creating pay history record: Violation of UNIQUE KEY constraint 'IX_Pay History'.

H
Written by Harry Ledger
Updated over 2 months ago

If you encounter this error message when trying to create a new pay history record for an employee, it means that the record you are creating is not unique to that appointment.
​
This is denoted by two fields in particular:

  • Pay From Date

  • Pay Element Type

These two values must be unique to the appointment, so, for example, you can't have an employee with the following record more than once in a single appointment:

  • Pay From Date = 01/01/2025

  • Pay Element Type = Basic Pay

You can either update the existing record if it is incorrect, or create a new pay history record with unique values (e.g., a different pay from date or pay element type).

Did this answer your question?