Need Resolution for the Error in the browser after submitting a catalog item request

Appu2
Tera Contributor

Hi, whenever I am trying to submit a new catalog item request it is giving me the error on browser "Unique Key violation detected by database ((conn=2340976) Duplicate entry '3454b5a31b65b910cfe2a827bd4bcb8a' for key 'PRIMARY')"

I haven't created aby business rules for this item but the drop down values for variables on form are coming from the table. Can anyone help me with the resolution of this error? Because of this error even the flow is not executing which I created for this item.

Appu2_0-1696391415017.png

 

1 ACCEPTED SOLUTION

@Appu2 ,

 

Look for all the before business rules runs on sc_req_item and sc_request check for current.insert or current.update in the script logic.

Easy way to find is :

Go to >business rules,

Filter conditions:

when -before

table - sc_req_item or sc_request

script contains>update or insert

verify if any BR exist, if you find deactivate and verify.

 

 

Accept and hit Helpful if it helps.

Thank you,
Hemanth
Certified Technical Architect (CTA), ServiceNow MVP 2024, 2025

View solution in original post

11 REPLIES 11

Arpan Baishya
Kilo Sage

Hi @Appu2,

 

Could you please try doing a code search for the text "current.update()" in ServiceNow Studio? Among the search results, check if there is such a line on any Business Rule that is related to any of the Service Catalog tables.

Let me know if any matches show up.

Hemanth M1
Giga Sage
Giga Sage
Hi @Appu2 , is this happening only for this catalog item or for all the catalg item???, i would double check existing business rules especially before business rule with current.insert/current.update As error indicates DB found a entry which already exist but system is trying to insert/update the same again.
Accept and hit Helpful if it helps.

Thank you,
Hemanth
Certified Technical Architect (CTA), ServiceNow MVP 2024, 2025

Appu2
Tera Contributor

It is happening for all catalog items!

 

@Appu2 ,

 

Look for all the before business rules runs on sc_req_item and sc_request check for current.insert or current.update in the script logic.

Easy way to find is :

Go to >business rules,

Filter conditions:

when -before

table - sc_req_item or sc_request

script contains>update or insert

verify if any BR exist, if you find deactivate and verify.

 

 

Accept and hit Helpful if it helps.

Thank you,
Hemanth
Certified Technical Architect (CTA), ServiceNow MVP 2024, 2025