cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Highlighted
Frequent Visitor

Filtering noreply email addresses

Hi,

I'm trying to create a filter for "noreply" email addresses in my Out of Office reply flow.

 

I created a Condition with the following expression:

@or(not(contains(triggerBody()?['From'], 'noreply')),not(contains(triggerBody()?['From'], 'donotreply')),not(contains(triggerBody()?['From'], 'no-reply')))

However, when I test it and a new email arrives in the Inbox this step just keeps running until it times-out.

 

You can see it in context here:

7598686835bf7b465cf2ab57cd65cf80f3f841e45d8282940ce6e7094c2ae4becbbd4ffb

 

 

6 REPLIES 6
Highlighted
Community Support
Community Support

Re: Filtering noreply email addresses

Hi @nhafala,

 

I tested it on my side using the expression you provided, Flow is executed as expected, and your expression is correct.

41.PNG

Could you provide more details about your needs?

Although I found that the expression you provided is correct after testing on my side, I doubt it if it can meet your expectations.

Because From field contains only the email address of the sender, there is no other information that can be used.

 

Best Regards,

Barry

Community Support Team _ Barry
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Highlighted
Frequent Visitor

Re: Filtering noreply email addresses

Hi @v-bacao-msft 

 

I find this flow a little too complex to describe. I exported the flow as a json. I tried to export as a zip file but it was impossible.

 

Please have a look here: https://gofile.io/?c=0F0Zaw

 

I also took a screenshot of the flow. Here it is: screencapture-emea-flow-microsoft-manage-environments-Default-c26d8596-66d7-4df4-a454-d2b749816fd2-flows-ee0fe7af-c1af-41cf-9284-294cd89f80dd-2018-12-17-14_56_37.png

 

 

Highlighted
Community Support
Community Support

Re: Filtering noreply email addresses

Hi @nhafala,

 

I want to know which step of your Flow is keep running.

The action such as Condition will only judge whether it is consistent according to the conditions. There is no behavior similar to the request to the server. It seems that the situation you describe will not appear.

And when testing on my side, the formulas you provide are correct, at least the syntax is no problem.

 

Best Regards,

Barry

Community Support Team _ Barry
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Highlighted
Frequent Visitor

Re: Filtering noreply email addresses

Hi @v-bacao-msft

 

Thank you for your reply. 

 

I run a test, this is what I got:

screencapture-emea-flow-microsoft-manage-environments-eda9993d-15a8-4a34-8d5e-f3deaf5713d5-flows-1fda5aa2-4b59-41e5-ba01-1f1d0d65340b-runs-08586563550110812990075210449CU49-2018-12-20-00_16_13.png

 

The condition that fails is the one that has this expression:

 

@and

    (

     greaterorequals(triggerBody()?['DateTimeReceived'], items('Apply_to_each')?['start']),

     lessorequals(triggerBody()?['DateTimeReceived'],items('Apply_to_each')?['end'])

       )

 

This is expression is meant to check which events are active at any given moment. It used to work without any problems, but it suddenly stopped working when I added more things to the flow below it.

 

These are all the details I can provide.

 

Highlighted
Community Support
Community Support

Re: Filtering noreply email addresses

Hi @nhafala,

 

I looked at the .json file from the link you provided, noting that the Expression configured in Compose 5 is the following:

@or(replace(outputs('Compose_4'),'January','Januar'),replace(outputs('Compose_4'),'February','Februar'),replace(outputs('Compose_4'),'March','März'),replace(outputs('Compose_4'),'May','Mai'),replace(outputs('Compose_4'),'June','Juni'),replace(outputs('Compose_4'),'July','Juli'),replace(outputs('Compose_4'),'October','Oktober'),replace(outputs('Compose_4'),'December','Dezember'))

Consistent with the error message display, the parameters you configure in the or() function are not boolean types, they are all of type String, so an error is generated.

Please make sure that the configured functions are configured as required.

For the use of Expression, please refer to the Online doc:

https://docs.microsoft.com/en-us/azure/logic-apps/workflow-definition-language-functions-reference

 

Best Regards,

Barry

Community Support Team _ Barry
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Highlighted
Frequent Visitor

Re: Filtering noreply email addresses

@v-bacao-msft

 

Thank you. I will check this briefly.

 

 

Helpful resources

Announcements
Community Conference

Power Platform Community Conference

Check out the on demand sessions that are available now!

Power Platform ISV Studio

Power Platform ISV Studio

ISV Studio is designed to become the go-to Power Platform destination for ISV’s to monitor & manage published applications.

Upcoming Events

Experience what’s next for Power Automate

See the latest Power Automate innovations, updates, and demos from the Microsoft Business Applications Launch Event.

Top Solution Authors
Top Kudoed Authors
Users online (7,351)