I am getting the following Error when i try to delete a Record from Report defination using OOTB Activicty DeleetRecord (Lock is held under open by Handle method)
This is the exception i am getting under server logs
The deferred delete failed with the following exception
com.pega.pegarules.pub.database.LockGoneException: Save, Delete or Commit has failed because lock "MYOR-DATA-DATATYPE1 4" is not held
at com.pegarules.generated.activity.ra_action_delete_426b3807cce477d72413775192bb9956.perform at java.lang.Thread.run(Unknown Source)
I have also configured the following SLA under Assigment Level
When i was trying to delete the record from the Grid which is sourced with Page List(sourced with RD) was facing the same error, so i tried to fix it with the approach as specified in my use case. May be you can have a look into it, so that it might help you for your customization.
Thank you Mahesh , i have got one more query how do we handle incase we need to delete multiple Records ( assume that a checkbox is present in RepeatGrid and need to delete all the selected ones )
Ok let me tell what i have done so far
Configured Repeating Grid with a CheckBox using pySelected Option and now under the Click Button calling an Activity
I am looping through the PageList under to find out all the pySelcted is true
Please let me know from next step what should be done ??
Posted: 4 years ago
Posted: 13 Nov 2017 8:24 EST
Umamaheshwar Reddy Midthuru (Mahesh Midthuru)
Principal Engineer, Technical Support, Customer Service
@Ravi, you can have the Delete button on grid header and on click of the button you can iterate over the Page List data in your activity then check for the pySelected property status, if it is true then you can perform the deletion of object from the page list. Also you can look into this discussion for some more information which might help you.
You can follow the same process for multiple records deletion also, the only difference is you need to iterate the Page list then delete the specific row which is being selected using DeleteRecord activity then reload the Page list to refresh the latest data into clipboard.