12-08-2005 07:23 AM - edited 03-13-2019 11:20 PM
I am receiving the following error when trying to add a new agent/supervisor in the Agent Explorer on the HDS server:
Configuration Manager
Failed to update the database
SQL Server Error
Error: 2627, State 2, Severity: 14
Violation of UNIQUE KEY constraint XAK2Person. Cannot insert duplicate key in object t_Person.
Db-Lib Error
Severity: 5
Db-Lib Error: 10007
General SQL Server error: Check messages from the SQL Serve
[press OK]
12-08-2005 02:50 PM
Did you manually add items into t_Person table? PersonID is primary key in that table, and is automatically generated by ICM when new agent is added. If any record insert is not awared by ICM, ICM could use that PersonID when adding new agent, and a conflict would happen.
Wei
12-09-2005 04:05 AM
No, I did not manually enter this item in the t-person table; however, this item was listed as an agent in Agent Explorer. I was having problems logging this agent onto the CAD application. Therefore, I removed this agent. However, now I am unable to add this agent back to the Agent Explorer. Where is the t-table located on the HDS? Your help is much appreciated!
12-09-2005 10:34 AM
PersonID exists in both t_Person and t_Agent table, can you compare the maximum PersonID from these two tables?
Select maximum(PersonID) from t_Agent (or t_Person)
with
select NextAvailableNumber from Next_Available_Number where TableName=Person
If the existing PersonID is equal and greater than the next available PersonID, the previous deletion wasn't completed properly. You might have to manually delete the items from t_Agent/t_Person, so that when ICM adds new agent, it would use the next available number.
Wei
12-09-2005 01:29 PM
Wei,
Thank you for your response. Where would I find the t_Agent or t_person table on the HDS?
12-09-2005 03:57 PM
Couple of ideas; you could have a Person created already with same name (John Smith for example). Also check Deleted Objects to verify that there aren't any Agents or Persons that haven't been permanently deleted. I'm pretty sure these items are just marked as deleted and you must permanently delete them. Also if the Person is already created and you are just creating the Supervisor you'll want to map the Supervisor to the proper Person, assuming the Person isn't linked already.
You can run SQL queries to check to Person and Agent tables. Just don't edit the database directly, only using ICM Configuration Manager.
12-09-2005 05:42 PM
AWDB
Discover and save your favorite ideas. Come back to expert answers, step-by-step guides, recent topics, and more.
New here? Get started with these tips. How to use Community New member guide