cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
UI1222
Advocate II
Advocate II

Prevent flow from running concurrently with same sharepoint ID

I have a flow that is triggered from a button in PowerApps. No problem. Everything works fine. Several differeret useres running the same flow concurrently... No problem, as long as the ID in the SharePoint list is unique. 

 

The flow takes 2½ minutes to complete.  Now at then it happens that the user clicks the button again, which will make both flows fail. 

 

I want to keep concurrent control off, but prevent the flow from running simultaneously with the same SharePoint ID. 

 

Is this possible? and what do i write in the trigger conditions? 

 

UI1222_0-1632342210138.png

 

1 ACCEPTED SOLUTION

Accepted Solutions
tom_riha
Super User
Super User

Hello @UI1222 ,

with Power Automate the flows are not aware of each other, so to give it information that the flow did already run on a specific SharePoint item you must keep the information in the item. I'd add a choice or checkbox field to the SharePoint list, e.g. 'FlowDidRun' and update it in the first action when a flow is started.

You can then build a trigger condition to trigger the flow only if the choice/checkbox has the default value (not the updated one).

The easiest way to create the trigger condition would then be with the 'Filter array' action, e.g.

image.png



[ If I have answered your question, please Accept the post as a solution. ]
[ If you like my response, please give it a Thumbs Up. ]

[ I also blog about Power Automate solutions even for non-IT people. ]

View solution in original post

2 REPLIES 2
tom_riha
Super User
Super User

Hello @UI1222 ,

with Power Automate the flows are not aware of each other, so to give it information that the flow did already run on a specific SharePoint item you must keep the information in the item. I'd add a choice or checkbox field to the SharePoint list, e.g. 'FlowDidRun' and update it in the first action when a flow is started.

You can then build a trigger condition to trigger the flow only if the choice/checkbox has the default value (not the updated one).

The easiest way to create the trigger condition would then be with the 'Filter array' action, e.g.

image.png



[ If I have answered your question, please Accept the post as a solution. ]
[ If you like my response, please give it a Thumbs Up. ]

[ I also blog about Power Automate solutions even for non-IT people. ]

View solution in original post

That it a great solution, i didn't think of that. 

 

Cheers

Helpful resources

Announcements
UG GA Amplification 768x460.png

Launching new user group features

Learn how to create your own user groups today!

Community Connections 768x460.jpg

Community & How To Videos

Check out the new Power Platform Community Connections gallery!

Welcome Super Users.jpg

Super User Season 2

Congratulations, the new Super User Season 2 for 2021 has started!

Carousel 2021 Release Wave 2 Plan 768x460.jpg

2021 Release Wave 2 Plan

Power Platform release plan for the 2021 release wave 2 describes all new features releasing from October 2021 through March 2022.

Top Solution Authors
Users online (1,443)