locked
Deleting PrincipalObjectAccess Records RRS feed

  • Question

  • A significant number of the records in our PrincipalObjectAccess table are granting shares to administrative accounts.  For example, every execution of a workflow results in sharing access to the WorkflowLog record with the owner of the workflow.

    Is there any problem with running an SQL job to delete PrincipalObjectAccess rows whose PrincipalId matches an admin user account which has no need of explicitly shared access to records?

    Monday, March 4, 2013 5:15 PM

All replies

  • Unless you have a valid business reason for keeping the workflow history, you might consider just turning it off. This can be done from the admin tab of each workflow (checkbox at the bottom). Then in the More Actions menu of the workflow history, you can choose Bulk Delete and remove the complete history.

    I would strongly advise against any direct SQL updates - it is unsupported and would likely result in data integrity issues.

    PrincipalObjectAccess–Performance Recommendations


    Jason Lattimer
    My Blog -  Follow me on Twitter -  LinkedIn

    Monday, March 4, 2013 6:01 PM
    Moderator
  • Thanks for the reply.

    Unfortunately, I would prefer to retain the workflow history since I have found it useful for debugging problems.  In addition, I have a similar issue with emails that are sent to CRM users from a CRM user representing the system.  These emails are shared with the "system" user and account for a significant number of PrincipalObjectAccess records.  I wish that I could just turn off the automatic sharing for the CRM users for which it provides no value - hence my question about just deleting the unnecessary POA records using SQL.

    I understand your advice about not doing so and I guess in the absence of any other options will have to evaluate the risks vs benefits. 

    Monday, March 4, 2013 7:41 PM