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

Send email 'When existing item is modified' triggers the send email 'When new item is created' flow.

SharePoint Online List with Flow

 

I have created 2 Flows on a SharePoint list:

 

1. Send an email when a new item is submitted

2. Send an email when an existing item is modified

 

They are both working, however when a new item is submitted, it triggers both emails (ie they are being duplicated). Is there a way you can just trigger the create email when new items are created without triggering the second Flow (when existing items are modified)?

 

We need an email to be sent when an item is created and also a different email to be sent when an existing item is modified.

1 ACCEPTED SOLUTION

Accepted Solutions
Super User III
Super User III

@Sam12 :

UPDATE:

After writing this, I learned much later that using the created and modified dates is not reliable.  Here is a link to a post that I wrote describing a better way of approaching this issue.

 

There is no SharePoint trigger that fires only when an item is modified.  The trigger you are using actually fires when an item is created OR modified.  If you used a template, the template name may have been a little misleading.....

 

To work around this issue, put a condition immediately after your trigger that compares the created and modified times.  If they are the same, then this is a new item.  You can use a control terminate action to end the Flow.  If you use the control terminate action, make sure you set the status to Success - it defaults to failed.

 

After the condition, your Flow can continue.

 

OnlyModified.jpg

 

If this answers your question, please mark your post as Solved.

If you like my response, please give it a Thumbs Up.

 

Scott

 

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

Scott

View solution in original post

1 REPLY 1
Super User III
Super User III

@Sam12 :

UPDATE:

After writing this, I learned much later that using the created and modified dates is not reliable.  Here is a link to a post that I wrote describing a better way of approaching this issue.

 

There is no SharePoint trigger that fires only when an item is modified.  The trigger you are using actually fires when an item is created OR modified.  If you used a template, the template name may have been a little misleading.....

 

To work around this issue, put a condition immediately after your trigger that compares the created and modified times.  If they are the same, then this is a new item.  You can use a control terminate action to end the Flow.  If you use the control terminate action, make sure you set the status to Success - it defaults to failed.

 

After the condition, your Flow can continue.

 

OnlyModified.jpg

 

If this answers your question, please mark your post as Solved.

If you like my response, please give it a Thumbs Up.

 

Scott

 

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

Scott

View solution in original post

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.

Top Solution Authors
Top Kudoed Authors
Users online (13,641)