Duplicate Entry....Invalid Insert - How to troubleshoot and identify cause?

stephen_gannon
Giga Contributor

I can create the Domain tree as needed but I am getting the error below when I try to Insert the 'ACME' domain


        Unique Key violation detected by database (Duplicate entry 'Acme' for key 'domain_u')

        Invalid insert


I have checked the error logs and found these:


Warning       Cancelling transaction #7714 /sys_db_object_list.do (cancelled by other transaction): Thread Default-thread-3 (stephen.gannon, 3F4EE1FF6FA0020093ACAA385E3EE441), after 13237ms       Transaction

and this;


Error       FAILED TRYING TO EXECUTE ON CONNECTION 17: INSERT INTO domain (`sys_updated_on`, `sys_id`, `parent`, `sys_created_on`, `type`, `sys_created_by`, `default`, `sys_domain_path`, `sys_domain`, `sys_updated_by`, `name`, `primary`, `active`, `sys_domain_code`, `sys_mod_count`) VALUES('2015-06-16 13:46:24', '6bafa1336fe0020093acaa385e3ee455', '11b914080f943100308a0eece1050ecc', '2015-06-16 13:46:24', 'Customer', 'stephen.gannon', 0, '!!!/!!$/!!!/!!#/', '6bafa1336fe0020093acaa385e3ee455', 'stephen.gannon', 'Acme', 0, 1, '!!#', 0)

Unique Key violation detected by database (Duplicate entry 'Acme' for key 'domain_u')



I   can't find the domain_u anywhere, or any Acme listed in the GUI and I can't see how to use the sysid for the referenced pre-existing Acme domain entry.


I have checked the Business Rules related to the Domain form, but no clues there either?

Any pointers on how to troubleshoot would be greatly appreciated.

Regards

Steve

12 REPLIES 12

Hey Stephen, sounds like a great idea!!


I wish i could have been more helpful. Hopefully next time



Please keep us posted on what the folks from Hi support say.



Thanks,


Berny


Hi Stephen,



Did you got any response from HI portal. Actually I am also stuck at same point in my case it is giving error of user not created and i can't even find the business rule have current.update() either . Do , let me know if you have the workaround for the same.


sergiu_panaite
ServiceNow Employee
ServiceNow Employee

Hi Stephen,



The error indicates platform is trying to insert a new record in domain table with a name of "Acme" which has a unique index defined in "domain_u". With the error there should be a stack trace as well. Can you post that here so I can check where the error is triggered from ?