web
You’re offline. This is a read only version of the page.
close
Skip to main content

Announcements

News and Announcements icon
Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Automate / When a "failure" is ac...
Power Automate
Answered

When a "failure" is actually a success in the end

(0) ShareShare
ReportReport
Posted on by 638

Greetings!!!

 

I got a flow that gets items from a Sharepoint list.

  1. It looks at the person field 
  2. using that person's email it queries o365 users
  3. End of story

Scenario A

If the user is valid

  1. sharepoint list is updated to reflect - yes this is an active user
  2. end of story

 

Scenario B

If the user is not valid or not found in o365 users, its considered a failure

  1. in a failure we move to another branch set to run only after previous failure
  2. Sharepoint list is updated to reflect - No this is Not active user
  3. End of story

 

My flow runs, it runs well and all updates are properly handled.

The hang up is that if our story ends via Scenario B, its considered a wholesale failure.

Looking at my flow history, = its a failure

 

How can I massage the flow to treat scenario B to also be a success?

Categories:
  • Verified answer
    AlanPs1 Profile Picture
    2,471 on at

    Hi @chico 

    It would be useful to see a picture of your complete Flow on this one, but if I am understanding correctly, the best way to mark a failure as a success, i.e, the fail is by design is to use a terminate action and mark it as "succeeded". If this suits your Flow design that is.

    Capture-505.png

    This may or may not fit your design though, please post your Flow and we will see.

     

    If you have found my post helpful, please mark thumbs up.

     

    Any other questions, just ask.

     

    Thanks, Alan

     

  • MattWeston365 Profile Picture
    1,701 on at

    Hi @chico you could always change the "run after" settings so that you can gracefully catch the error. You can do this by clicking on the ellipsis for the step following the failing action and set it to run on Error. This usually works better if you contain all of your logic in scopes. Whilst this will work, the inner developer in me is screaming no 🙂

     

    What I would suggest for a cleaner approach would be to use "Search for Users" and search for the email address. If the length of the body returned is 0, then the user doesn't exist. If it's greater than 0, then you have a match.

     

    Search.PNG

     

    The expression I have used in the condition is:

    length(body('Search_for_users'))
     
    This will at least give you a True/False test which will mean your Flow is a lot cleaner than if you're relying on an error state.
     
    If you have found this post useful, please give it a thumbs up. If it has answered your question, please accept it as the solution so others can benefit.

    @MattWeston365
     
  • chico Profile Picture
    638 on at

    @AlanPs1 

    awesome input, thank you!

    will be exploring this today!

  • chico Profile Picture
    638 on at

    @MattWeston365 

     

    awesome input, thank you!

    will be exploring this today!

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Season of Sharing Community Challenge Winners!

Congratulations to our community stars!

Kudos to our 2025 Community Spotlight Honorees

Expanding mentorship, skilling, and AI innovation

Leaderboard > Power Automate

#1
Mohsin Ali Profile Picture

Mohsin Ali 389

#2
11manish Profile Picture

11manish 345 Super User 2026 Season 2

#3
M Bilal Khan Profile Picture

M Bilal Khan 308

Last 30 days Overall leaderboard