For each contact record I need to restrict it with having only one related record.[ related record like job category or job role, both of them are separate entities]
If a contact updates his information about his job category or role on the website, I want to create a new related record and deactivate the previous ones. In that way there will be only one active record.
Any suggestion how I can do this?