Page 1 of 1

Duplicating Widgets and PK Constraint Issue

Posted: June 1st, 2023, 1:21 pm
by shalomsims
When I duplicate a widget, sometimes (I cannot determine what makes this occur) I get a pk constraint error on the SubMethod or Loop. I understand that we cannot create two submethods/loops with the same ID (PCN-xxxxxx) which I assume is happening when duplicating but that seems like what might be happening.


Also, when attempting to duplicate a widget, the message says that the statement was terminated but it actually does duplicate the widget. Everything gets duplicated except the services in the model and controllers. They are empty. The parameters, events, and controls in the View are all there but there are no services in the Model or Controller. There has been a case where the View was not there, but I have not been able to recreate that.


As part of this issue, when promoting a widget from QA to PD, an error is thrown sometimes for SubMethods and Loop services with a duplicate pk. The temporary solution for this is deleting the service and recreating it again. This is also the solution for the former issue