Case Management Framework Grant Access To Case Definition Issue
Application Type
Reactive, Service
Platform Version
11.9.2 (Build 29615)

Hi


Had an issue with the case management frameworks Case_Definition_GrantAccessToGroup Server Action in Case_Services_API. When trying to add multiple groups to the same Case Definition I got this error: 


Cannot insert duplicate key row in object 'dbo.OSUSR_54X_CASEDEFINITIONACCESSCONTROL' with unique index 'OSIDX_OSUSR_54X_CASEDEFINITIONACCESSCONTROL_6USERID_16CASEDEFINITIONID'. The duplicate key value is (<NULL>, 23e88a6e-86c7-4bcf-8131-7fa875be4f09).

The statement has been terminated.



I looked in the DB and found that there is a unique index of The casedefinitionid and userid . because it's a api call there is no user id aka user id is NULL always ?. I fixed this on an on prem environment  by making the index non-unique but is there a solution for the cloud environment ? 


Index name: OSIDX_OSUSR_54X_CASEDEFINITIONACCESSCONTROL_6USERID_16CASEDEFINITIONID

Hi 

Issue is resolved via support: 


"The issue has been identified and we will be releasing a new CMF(Case Management Framework) version release through forge that will fix the issue in 2 weeks' time (week of May 24th). (version 1.5.0)"


Thanks

Gayan

Hi  @Gayan De Saram ,

Open the Indexes tree under your table. You will find an Index named 'OSIDX_OSUSR_54X_CASEDEFINITIONACCESSCONTROL_6USERID_16CASEDEFINITIONID '.

Script out that Index and you will see that it is a UNIQUE index on a "name" column that you are trying to create a duplicate value in.

Just once again you can check there and You must either change that Index Or your attempt to create a new row with a duplicate name. 


Thanks 

Purva Kumbhar

Hi @Purva Kumbhar

Yup i am able to fix the issue using the DB and removing the unique on the index, I can't change the value as one is USERID which the Case_Definition_GrantAccessToGroup doesn't have a parameter for (always seem to do NULL) and the other is the CASEDEFINITIONID which cannot be unique (Otherwise multiple groups can't have access to the same cases). I'll open a support case for this with outsystems and see if they can me something. Will post the answer back here.

Thanks
Gayan

Hi 

Issue is resolved via support: 


"The issue has been identified and we will be releasing a new CMF(Case Management Framework) version release through forge that will fix the issue in 2 weeks' time (week of May 24th). (version 1.5.0)"


Thanks

Gayan

Community GuidelinesBe kind and respectful, give credit to the original source of content, and search for duplicates before posting.