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 / Condition does not han...
Power Automate
Answered

Condition does not handle missing data

(0) ShareShare
ReportReport
Posted on by 2
I am struggling with the Condition failure step.
 
Plan:
 
1) I have a sharepoint List, with users inside (name, e-mail, activity column)
2) This activity column has to be updated from O365 (yes, no)
3) I search for the users' email addresses with "Search for users (V2) where "Is search term required" is set to No.
4) After the search a Condition work with: accountEnabled is equal to true.
5) If yes, the List's Activity field should be updated with "Yes" text | If no, it should be updated with "No" text
 
List:
 
 
 
 
Flow:
 


 
Problem:
 
If the user exists in O365, it works, the "Yes" answer will be updated in the List.
But for non-exisiting users (tested with dummy email), the Condition does not do anything, the "No" will not be updated.
 
 
I don't understand why, if it seems clearly that the "if yes" was not true, so the "if no" should be go.
 
Which is interesting, that the same works great with "Get user profile (V2)" action, but it's not good for me because I need to search for email addresses instead of UPNs (it's not always the same).
 
Thank you!
Categories:
I have the same question (0)
  • Verified answer
    Michael E. Gernaey Profile Picture
    53,958 Moderator on at
    Hi,
     
    The issue is, that there are no records for the Apply to Each to loop through. Its not going to loop once just so you can get a no.
     
    If you think you are only getting 1 record then do this instead
     
    Remove the Apply to each
    Add a Condition
    left side (Length(thedynamicbody/valuefromProfielSearch) is equal to 1
     
    This way it will trigger the Yes side if it exists or the No side if not.
     
    Blank Arrays do not trigger Apply to each, thats why it shows as Green as it did what you asked based on the data, nothing.

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

Introducing the 2026 Season 1 community Super Users

Congratulations to our 2026 Super Users!

Kudos to our 2025 Community Spotlight Honorees

Congratulations to our 2025 community superstars!

Congratulations to the April Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Automate

#1
Vish WR Profile Picture

Vish WR 1,027

#2
Valantis Profile Picture

Valantis 809

#3
Haque Profile Picture

Haque 645

Last 30 days Overall leaderboard