Unable to submit a Service Contract


When trying to create a Service Contract (Contracts - Service Level Management Menu Option) Customer is able to input the necessary data such as start & end dates, financial and supplier details, however when trying to submit for review an error message is generated [unique key violation detected by database].

Release or Environment



Custom business rule that calls a custom script include rule which is doing additional security checks. Specific user profile is missing something that the custom script include is checking for.

Issue doesn't occur for maint/admin


The error displayed is usually generated by a custom business rule with current.update() in the code.

Noticed that new contract records were actually created even though the error was thrown.

No new records are displayed when impersonating the user but when I stopped impersonating and opened the service contracts table list view, I could see new records were added.
I initially thought this could be ACLs but security debugging didn't show any missing/failing ACLS.
I checked and the user has the required roles.

Reproduced the issue with debug tools to see what business rules execute when the error occurs.
The debug shows this business rule executes.
UP3 Contract Query Rule

The business rule calls this Script Include
Script Include that contains functions for controlling the security of contracts for Cox.

This custom configuration seems to be doing additional security checks and the users profile is missing something that the custom script include is checking for.

To test, I disabled this business rule and the error no longer displays and the contract records are all displayed in the Service contracts list. (while impersonating the affected user)