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

Condition/Multiple emails Issue

One of my flows (trigger = 'when a file is created or modified') conditionally sends an email based on the value of a cell in an Excel file ('Status' = 'FA SUBMITTED'), and also updates the 'Status' field (to prevent repeated emails being sent).  It ran for months without any issue, but recently it has sometimes sent multiple emails if runs happen very close together (e.g. 30 s apart).  As you can see from the images below, the flow ran twice in quick succession, and I suppose the updating of the Status action from the first one did not happen quickly enough for the second run to return 'True' on the condition, which resulted in a redundant email being sent.  (On the data-entry side, the 'Status' field is the last field to be entered.)

 

I am not sure whether multiple people editing the spreadsheet at the same time is causing this, or whether putting the condition in the trigger instead of the body of the flow might fix things, in which case, I am not sure of how to formulate the condition.  Any help would be greatly appreciated!

Flow ConditionFlow ConditionUpdate StatusUpdate Status1st Run (1/20/20 10:47:21 AM)1st Run (1/20/20 10:47:21 AM)2nd Run (1/20/20 10:47:51)2nd Run (1/20/20 10:47:51)

 

1 ACCEPTED SOLUTION

Accepted Solutions
cluebbe
Frequent Visitor

Thanks everyone for your responses!  I sort of solved the issue by inserting a Compose action that gets the last row of the Excel table and changing the multiple Condition actions to a single Switch, which is much faster and avoids the multiple triggering.

View solution in original post

4 REPLIES 4
v-bacao-msft
Community Support
Community Support

 

Hi @cluebbe ,

 

This seems to be the expected result because the trigger you set and the Update a row action conflict.

 

The role of the Update a row action is to change the file. After the execution of this action ends, Flow will be triggered again, and it will be triggered infinitely.

 

It is not recommended to configure a trigger such as When a file is created or modified and action with the ability to change files in the same Flow.

 

Best Regards,

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.

Hi Barry,

Thanks for your response.  I understand the idea of an infinite loop, but that doesn't seem to be what is happening (in part because the update row only happens if the condition returns 'true', and since the update row changes the status, even if it triggers another run, then the next run should return 'false' and not modify the file thereby preventing an infinite loop, unless I'm missing something, which it completely possible). 

 

The flow runs fine most of the time, it is only on occasion that it sends multiple emails, so I tend to think it is a data-entry issue.  I am completely open to starting from scratch, but would also like to definitively diagnose what is causing the issue.

Brad_Groux
Community Champion
Community Champion


@cluebbe wrote:

The flow runs fine most of the time, it is only on occasion that it sends multiple emails, so I tend to think it is a data-entry issue.  I am completely open to starting from scratch, but would also like to definitively diagnose what is causing the issue.


This is because the Excel connector has many Known issues and limitations. In recent years, Microsoft has greatly reduced the overall functionality of the Excel connectors to try and convince users to migrate off of it.

For this reason, the Excel connector is not recommended if at all possible. If you can, you may want to consider migrating your Excel table(s) to a SharePoint List. Due to the issues, the reliability of the Excel connectors for heavy workloads is spotty, at best.

👨🏻‍💻 If this reply answers your question or solves your issue, please ACCEPT AS SOLUTION ☑️. If you find this reply helpful, please consider giving it a LIKE 👍.

cluebbe
Frequent Visitor

Thanks everyone for your responses!  I sort of solved the issue by inserting a Compose action that gets the last row of the Excel table and changing the multiple Condition actions to a single Switch, which is much faster and avoids the multiple triggering.

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 (2,869)