BBECRM: Business process output delete is clearing more tables from the history than it is set to

Over time your database can accumulate business process output files you no longer need. For example, in Export, the export generates output files in SQL tables that are available to download to a .csv file. To remove unneeded output files from the database, use the Delete business process outputs global change process. This process completely removes the SQL table(s) that hold output for the selected business processes. This process can be set to delete all but the X most recent runs. Users may find that the process is deleting more from the history than the number of runs that it is set to.

The functionality to delete historical Business Process output is not process-specific.  If you set it to to delete all but the last 5 process runs, the system will preserve only the last 5 processes ran with no regard to type.  

Example: 
If "Process A" runs 2 times and then "Process B" runs 5 times after that, deleting all but the last 5 will preserve the "Process B" runs only.  

There is an existing entry in our Ideas Portal to enhance the existing functionality to filter this functionality in a more granular fashion: 
https://bbcrm.ideas.aha.io/ideas/CRM-I-97

Steps to Duplicate

Steps to duplicate: 

1.  Navigate to Administration > Database growth management > Business process history tab
2.  Add a new global change "Business process output delete"
3.  Click on "Selected business processes" and create a query to Include records where : Name is equal to Export Process and save.
4.  On the option for "Delete output tables" click on for all but the most recent X runs and set to 2
5.  On the Database Growth Management Page on the Business Process History Tab; filter Top processes by Type: Export Process.
6. **Optional depending on the database; We need export processes that have been run more than 2x and have generated data for the following steps** If there are not any processes that have been run over 2 times or not a big enough sample > Open Administration > Export and run the Export Process for a few of the Exports with a type of "Export definition" at least 3x for each process that is going to be tested.
7.  Navigate to Administration > Database Growth Management > Click on the "Refresh analysis" button under Tasks at the top left of the page (this will take a few minutes) Then click on "Go to results"
8.  Click on the Business Process History tab and filter the results by Export Process. Note the number of processes that show up here and verify that if you click on the process name and the history tab that "download output" is available for more than 2 versions in the history.
9.  Run the Global change created in Step 2.
10. Return to Database Growth Management > Business Process History page and look through the history of the various Export Processes and note that many have been completely cleared, some may have had all but 1 removed and some may have had the history cleared as set.
11. Run the Refresh Analysis again (this will take a few minutes).
12. Note the process list now may only have a few processes that have any history left.

Environment

 Blackbaud CRM
 4.0
 4.0.1.168.37

Was this article helpful?