Flow and Process Builder List View with Batch Delete

Flow and Process Builder List View with Batch Delete

I’ve been following a couple of ideas on the Idea Exchange for a while now.  One has over 11,000 points and 13 merged ideas.  Process Builder – List View and the other Allow Mass Deletion of Inactive Process Builder Versions has over 4,000 points with 4 merged ideas.

I don’t know about you, but I get pretty frustrated trying to view and keep track of all of my Flows and Process Builders.  A better List View would certainly be appreciated.

When it comes to trying to clean things up and delete some old inactive versions, it becomes downright painful.  

  • Find the Process Builder, 
  • Expand the list, 
  • Find the old version, 
  • Click Delete, 
  • Click Confirm, 
  • Wait,
  • Wait some more, 
  • Go to select the next one — 
  • Oh ^#%$@ I have to start all over again!!!

I decided to put my Datatable component to work and updated it to support Apex-Defined object variables.  Using data pulled from three different Salesforce internal objects, I’m able to display details about Flows and Process Builders.  The full power of the Datatable component comes into play by offering a List View with sorting, highlighting, filtering and more.

Taking advantage of the Datatable’s ability to select multiple records and pass them along in a Flow to be acted upon, I created a Flow Action that interfaces with the Metadata API and handles the batch deletion of the selected inactive Flows and/or Process Builders. 

I’ve bundled all of this together in an App that includes a configurable List View, List View with batch selection for delete and a Flow Picker where you can select a single Flow or Process Builder and then work with a List View of all of its active and inactive versions.

Here’s a video of the component in action.

Installation Instructions

Instructions

Source Code

23 thoughts on “Flow and Process Builder List View with Batch Delete

  1. Very interesting. I am also looking for ideas on how to incorporate a master process builder controller that decides which process builder to call that all listens to the same object. Goal is to minimize multiple process builders that listen to same object but have unique filter/decision criteria. Any ideas or references?

    Like

  2. Hi Eric,

    This is brilliant. I am using user defined objects to setup a table in my flow and it displays the details accurately. But I am facing a problem in the selection output variable. If I select three from the table displayed, the output does show three selection but the content is always of the first option. I cannot use the selection further. Also the preselect string does not show the preselected records. Can you help please. Am I doing something wrong here?

    Like

  3. What is meant by “Deletion result is: Pending”?
    I’ve selected about 50 flow versions to delete, and see this after clicking next. I’ve waited over 10 mins but the flow versions aren’t being deleted. Can I check on the pending jobs anywhere?

    Like

      1. I can see all the flow versions after clicking ‘View Details and Version’ and the inactive versions are still there after running though the batch deletion, and getting the ‘Pending’ deletion result from the flow. I would expect them to have been deleted by now. Can I check on the deletion job progress?

        Like

    1. I tried selecting 5 out of the list to delete. The batch delete flow ended with ‘Deletion result is: Pending’ again, and after 10 mins, the flow versions have still not been deleted.

      I have had success deleting multiple other flows and PBs with this app, but these particular flow versions do not want to be deleted for some reason.

      Like

    2. Aha! If I try to delete the flow version in the regular Salesforce UI, I get a number of notices that say “This flow version is referenced elsewhere in salesforce.com. Remove the usage and try again.”, and beside that is a hyperlinked Flow Interview.

      Clicking on the flow interview takes me to a flow that appears to have failed, since it has a ‘Paused or Failed Date’.

      I wonder if the new addition of ‘Paused And Failed Flow Interviews’ in setup in the Summer ’21 release has complicated this process?

      Deleting the failed flow interviews allowed me to manually delete the flow interview. I then tried the batch delete app again, and got the ‘Deletion result is: InProgress’. After a moment, I checked the list of flow versions, and they were all successfully deleted.

      Thanks for your help Eric!

      Like

  4. Hi Eric,

    I have been installed the tool in my Sandbox and facing one issue. After selecting Select the Flow you would like to Run in Full Screen mode –> Select a Single Flow or PB with Option to Delete Inactive Versions (3 Options) –> Process Builder –> Select the inactive Process Builders and/or Flows you want to DELETE and select Next. It’s not displaying (fetching) any rows. Could you help me with this issue?

    Thanks
    Vishnu VS.

    Like

      1. Yes, I am running as System Administrator. I ran the flow “Flow and Process Builder List View” in Debug Mode, I got the Active versions of Process Builder’s in the results section (Debug Details) but not on the layout.

        Like

  5. Has anybody had an issues lately? Trying to run it and keep getting empty table. Tried redploying from github for latest version updates and resaving the flows to get recent API version but didn’t help.

    I tried to debug one of the flows and can see the data is being pulled but nothing in the table shows.

    Like

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s