Skip to main content
Community site session details

Community site session details

Session Id :
Power Automate - General Discussion
Unanswered

Flow that sends out emails

(0) ShareShare
ReportReport
Posted on by

Hi I have a flow that attaches 2 unique files into an email then sends a message to 80+ recipients, all works fine.

The issue is that when it is complete it returns a failed message as if it hasn't worked, but it has!

Any ideas? This is the message:

The execution of template action 'Filter_array' failed: The evaluation of 'query' action 'where' expression '@contains(item()?['Name'], items('Apply_to_each_2')?['field_0'])' failed: 'The template language function 'contains' expects parameters of matching types: a dictionary and a key (string), an array and a value (object), or a string and a substring. The provided types 'String' and 'Null' are incompatible. Please see https://aka.ms/logicexpressions#contains for usage details.'.

 

Thanks

  • VictorIvanidze Profile Picture
    12,536 on at
    Re: Flow that sends out emails

    Show your flow.

  • wskinnermctc Profile Picture
    6,517 Super User 2025 Season 1 on at
    Re: Flow that sends out emails

    Do you have any values that are Null within that condition? If so, you should put an empty() check within the expression so that if a value is null, it does something else instead of trying to compare null to a string.

     

    So like:

    contains(item()?['Name'],if(empty(items('Apply_to_each_2')?['field_0']),'NoField',items('Apply_to_each_2')?['field_0']))

     

    I don't know exactly how you need to arrange it, but try using empty somewhere as a way to deal with null values.

     

    I don't know if this will solve your problem, but I would test the approach to see if it works.

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

Paul Stork – Community Spotlight

We are honored to recognize Paul Stork as our July 2025 Community…

Congratulations to the June Top 10 Community Leaders!

These are the community rock stars!

Announcing the Engage with the Community forum!

This forum is your space to connect, share, and grow!

Leaderboard > Power Automate

#1
Michael E. Gernaey Profile Picture

Michael E. Gernaey 497 Super User 2025 Season 1

#2
David_MA Profile Picture

David_MA 436 Super User 2025 Season 1

#3
Riyaz_riz11 Profile Picture

Riyaz_riz11 244 Super User 2025 Season 1