cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
bnerd
Advocate I
Advocate I

Can't check if a document library (multiselect) Person/Group column is empty or not

I have a document library with Person or Group column on which multiple selection is allowed.

bnerd_0-1601544469915.png

My flow should check if there is a value on this column before it attempts to send an email

bnerd_1-1601544643586.png

When I run my flow on documents with no value in the Contact column, the flow does not fail but it simply stops on the Condition like so:

bnerd_2-1601544721255.png

My aim is to use the Condition to either email the person on the Contact column, or if empty, email administrator and prompt them to add the Contact person in. Currently I'm not able to do this as the flow just stops running, even though it is not showing as fail.

 

I know flow did not used to support People or Group columns where multiple values are allowed but apparently this has been implemented https://powerusers.microsoft.com/t5/Power-Automate-Ideas/Person-or-Group-field-in-item-should-suppor... so not sure what is happening here...

 

1 ACCEPTED SOLUTION

Accepted Solutions
manuelstgomes
Super User
Super User

Hi @bnerd 

 

In the condition, try the following:

 

length(<insert here your list column reference>)

 

and set the condition to equals 0.

 

SharePoint returns an array, so you're checking if the array is empty or not.

 

Can you please check if and let me know if you have any questions?

 

If I have answered your question, please mark your post as Solved.
If you like my response, please give it a Thumbs Up.

Cheers
Manuel

View solution in original post

3 REPLIES 3
manuelstgomes
Super User
Super User

Hi @bnerd 

 

In the condition, try the following:

 

length(<insert here your list column reference>)

 

and set the condition to equals 0.

 

SharePoint returns an array, so you're checking if the array is empty or not.

 

Can you please check if and let me know if you have any questions?

 

If I have answered your question, please mark your post as Solved.
If you like my response, please give it a Thumbs Up.

Cheers
Manuel

View solution in original post

Thanks for the suggestion @manuelstgomes but that has the exact same problem. I changed the Condition as suggested:

bnerd_0-1601552939541.png

and again, flow runs with success but neither Yes or No branches are executed:

bnerd_1-1601553016474.png

 

My bad @manuelstgomes. I changed the flow so the Condition is outside and before 'Apply to Each' block and that did the job. Thanks! Flow now runs correctly:

bnerd_0-1601553963394.png

 

Helpful resources

Announcements
MPA_User Group Leader_768x460.jpg

Manage your user group events

Check out the News & Announcements to learn more.

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.

Users online (1,422)