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

Appu2
Tera Contributor

No BR Exists with these filters

Appu2_0-1696393772185.png

 

Tai Vu
Kilo Patron
Kilo Patron

Hi @Appu2 

Take a look at the following post:

https://www.servicenow.com/community/developer-forum/unique-key-violation-detected-by-database/m-p/1...

 

double-update.png

 

It appears that there might be a situation where a double update is being performed when you submit the form.

Appu2
Tera Contributor

Thanks all for the suggestions. I got the error resolved.

That's cool.

@Appu2 :great, you can mention what’s the cause (if it’s not confidential) so that other can refer if they run into same issue 

And also close this loop.

Accept and hit Helpful if it helps.

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