cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
MS_Sol
Level: Powered On

Prevent flow result as failed when using configure run after to handle expected

I am using the error handling functionality to get an entity from an Azure table and on failure add the entity if it doesnt exist.  As far as I know this is the only way to handle this requirement to not create duplicate entities.  

 

The flow attempts says they failed when in fact the parallel actions for failed attempts to get the entity did add the entity as desired.  This gives the impression that the flow isnt working.  Also, I wont know if it every really doesnt work because it will be always saying failed except when there is an existing entity.

 

Am I missing something, or is this a gap in the solution?  Seems like you could have a setting on the confiure run after to not mark the flow as failed

1 ACCEPTED SOLUTION

Accepted Solutions
MS_Sol
Level: Powered On

Re: Prevent flow result as failed when using configure run after to handle expected

I figured it out.  FIrst, I changed from get entity to get entities.  Then the data comes back in one of the outputs as JSON.  I took some sample JSON from the response and added parse JSON action using that to build my schema.  Now the parse json output has each of my properties

 

resource 1.JPG

View solution in original post

3 REPLIES 3
Community Support Team
Community Support Team

Re: Prevent flow result as failed when using configure run after to handle expected

Hi @MS_Sol,

 

Could you please share a full screenshot of the configuration of your flow?

Can you provide flow run details?

Do you mean that Flow added entity as expected, but shows Failed?

Please check and see if the following blog would help:

https://flow.microsoft.com/en-us/blog/error-handling/

It would be helpful if you could post some screenshot.

 

Best Regards,

Barry

Community Support Team _ Barry
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Highlighted
MS_Sol
Level: Powered On

Re: Prevent flow result as failed when using configure run after to handle expected

The flow checks for a record is the table.  If it is not there, then it does a bunch of actions and then insert a record in the table.  The idea is the actions should only be done if there is no record.  Since my flow is configured for error handling and the failure is expected and configured to take actions, I would expect the flow runs to be listed as successful not as failures.  If flow has actions to check for records without using an error to handle it, I would, but it doesnt.  In any other coding a handled error can be set to not show the run as a failure (and ususally is by default)

 

Here is the snipet of the part of the flow:

 

resource 1.JPG

MS_Sol
Level: Powered On

Re: Prevent flow result as failed when using configure run after to handle expected

I figured it out.  FIrst, I changed from get entity to get entities.  Then the data comes back in one of the outputs as JSON.  I took some sample JSON from the response and added parse JSON action using that to build my schema.  Now the parse json output has each of my properties

 

resource 1.JPG

View solution in original post

Helpful resources

Announcements
firstImage

New Ranks and Rank Icons in April

Read the announcement for more information!

firstImage

Better Together Contest Finalists Announced!

Congrats to the finalists of our ‘Better Together’-themed T-shirt design contest! Click for the top entries.

firstImage

New & Improved Power Automate Community Cookbook

We've updated and improved the layout and uploading format of the Power Automate Cookbook!

thirdimage

Power Automate Community User Group Member Badge

Fill out a quick form to claim your user group badge now!

sixthImage

Community Summit North America

The top training and networking event across the globe for Microsoft Business Applications

Top Kudoed Authors
Users online (9,437)