cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
SylvieLet17
Responsive Resident
Responsive Resident

Contains Condition always false

Hi all, 

I have checked all the similar questions here but nothing worked for me. It's not a case sensitivity issue. 

I have a flow like this:

When a (sharepoint list) item is created or modified

Get item

Initialize groupsVar (Array of choice field with multiple selections enabled)

Condition: If groupsVar contains "Mission", send an email. 

 

One of the possible choices is Mission Groups. I have tried 'Contains "Mission Groups" ' but it still does not work. 
I even added a compose with "Contains "Mission groups" ' which is also returning false. compose.pngCompose2.png

1 ACCEPTED SOLUTION

Accepted Solutions
SylvieLet17
Responsive Resident
Responsive Resident

Solved it, I guess it's because the output is considered an object, not a string. It doesn't throw an error, but it isn't able to register the word in the string because it's an object. That's my guess anyway. 

The fix was to use a compose action, with formula: 

string(variables('groupsVar'))
to convert the object into a string, and then I used the compose outputs in my condition. 

View solution in original post

3 REPLIES 3
SylvieLet17
Responsive Resident
Responsive Resident

Solved it, I guess it's because the output is considered an object, not a string. It doesn't throw an error, but it isn't able to register the word in the string because it's an object. That's my guess anyway. 

The fix was to use a compose action, with formula: 

string(variables('groupsVar'))
to convert the object into a string, and then I used the compose outputs in my condition. 

@SylvieLet17 

 

Hi - could you please post an image of flow? 

I am having issues with my conditions and keen to give this a go. 

Thanks, 

Summer 

colzz_0-1645151223841.png

 

Helpful resources

Announcements
Power Platform Conf 2022 768x460.jpg

Join us for Microsoft Power Platform Conference

The first Microsoft-sponsored Power Platform Conference is coming in September. 100+ speakers, 150+ sessions, and what's new and next for Power Platform.

New Ideas Forum MPA.jpg

A new place to submit your Ideas for Power Automate

Announcing a new way to share your feedback with the Power Automate Team.

MPA Virtual Workshop Carousel 768x460.png

Register for a Free Workshop

Learn to digitize and optimize business processes and connect all your applications to share data in real time.

365 EduCon 768x460.png

Microsoft 365 EduCon

Join us for two optional days of workshops and a 3-day conference, you can choose from over 130 sessions in multiple tracks and 25 workshops.

Users online (4,997)