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

Issue with Flow sharepoint list item modified

Hello!

 

I have an annoying situation.. I have a flow that is triggered by a new list item but i also have a flow triggered for when an existing item is modified.  What is happening is everytime a flow is created, it triggers my modified flow, resulting in 2 approval emails being sent.  Can anyone help with a workaround?

 

I am attempting to add a condition of created at time, but my syntax is not working.

 

Condition is as such on the modified item flow:

@greater(item()?['Created'],addminutes(utcnow(),1))

 

This is being ingnored for some reason.

Thanks!

12 REPLIES 12
douglasromao
Kudo Kingpin
Kudo Kingpin

Hi @mat_it_guy,

 

You have some ways to do it:

 

  1. Create a column to set if the flow was executed;
  2. Use just the modified flow (because always when a item is created this flow will execute;
  3. Check if the Created date is equal to Modified (When we create a item, they will be equal);

 

If you need something, please contact me.

Regards,

Douglas Romão

Thanks for the comment, I hadn't thought of using just the modified flow.

 

As far as comparing the created and modified times, this still fires off, im thinking it keep tracks of seconds, and the fact that they are produced a second apart, they trigger the flow.

 

Thanks,

@mat_it_guy,

 

Here we are using only the modified trigger to do solve this approach.

Great! And have you all resolved the timezone issue?  I am in EST and when an approval email is sent with a time and date it is defaulted in GMT.

thanks again

@mat_it_guy,

 

Unfortunately I think we are not able to change this, I´ve searched here on flow forums and with some friends that are working with flow too but I found nothing about it. Smiley Sad

 

I´ll keep searching and if reach something, I tell you ok?

Amazing! I'll do the same.

 

Thanks alot for your time!

Cool @mat_it_guy! If you need something, please don´t hesitate to contact me, we are here to help each other. Smiley Very Happy

 

Regards,

Douglas Romão

Hello,

I'm having exacctly the same problem.

I cannot use only the modify flow because I need to do different things when it's created and when it's modified.

I was trying to use the first suggestion of creating a new column to set if the flow was triggered but I cannot figure it out. @douglasromao Any ideas of how I could do it?

Not sure if this will help.

 

I use a service account to execute all of my flows, and I am the only one with access to this account. That being said, I have added a condition at the beggining of my flow verifying if the modification was done by my service account, if so, i terminate the flow.

 

If not, i proceed with the change.

 

Otherwise if my previous suggestion is no help.  Have you considered running 2 different flows?  I have noticed that you can now chose either when an item is created or when an item is modified as a trigger. (flow used to package these 2)

 

If so, just run 2 different flows and they will know when to trigger.  You might want to consider using the service account check condition if you use this approach as it will surely fire off once an item is modified.

 

Let me know if this works! Flow needs many more improvements before it becomes a viable and easy to use solution.

Thanks a lot!

Yes I actually have 2 flows: 1 for when an item is created and 1 for when an item is modified, but it was still running both.

I am also using a service account to run the flows and previously I have tried what you mentioned but maybe I was doing it wrong.

I added a condition in my modify flow to check if the modified by account was my service account, if not continue the flow.

It is working now as expected 🙂

Thanks again.

 

Great! To help the flow community please take a moment and click Accept as solution on the thread message with the solution.

 

Thanks!

I'm sorry @mat_it_guy but i don't see that option. I'm guessing because I didn't start the thread. Maybe only you can mark your own answer as solution 🙂

Helpful resources

Announcements
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.

New Process Advisor Capabilities carousel.png

Read the blog for the latest news

Read the latest about new experiences and capabilities in the Power Automate product blog.

PA Survey Carousel Image.png

We want to hear from you!

If you are a small business ISV/Reseller, share your thoughts with our research team.

Users online (3,719)