cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Highlighted
CameronTCD
Level: Powered On

My 'Update SharePoint Item' within an 'Apply to Each' doesn't run

Hi

 

I'm having an issue whereby my Flow will run successfuly but still (for some reason) not run the 'Update Item' connector... which is the most important part of the Flow.

 

Any advice/suggestions would be greatly appreciated. 

 

OoHF0ts.png

 

6 REPLIES 6
Super User
Super User

Re: My 'Update SharePoint Item' within an 'Apply to Each' doesn't run

Could you supply more detail on what is controlling the Apply to each and how your update item is configured?



-------------------------------------------------------------------------
If I have answered your question, please mark your post as Solved.
If you like my response, please give it a Thumbs Up.
CameronTCD
Level: Powered On

Re: My 'Update SharePoint Item' within an 'Apply to Each' doesn't run

@Pstork1 

 

I have provided two screenshots below.

 

Regards,

Cameron1.png2.png

 

Super User
Super User

Re: My 'Update SharePoint Item' within an 'Apply to Each' doesn't run

I assume the id in your update is coming from the Get unique request ticket action before the loop.  If that's the case then the problem isn't that your update isn't running.  Its that the update runs each time the loop cycles and you are over-writing earlier updates.   So the only one you are actually getting is the last one in the loop, which is probably empty so it looks like the update didn't run.



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

Re: My 'Update SharePoint Item' within an 'Apply to Each' doesn't run

Hi @CameronTCD ,

 

Since you have configured Filter Query, Get items actions only returns items that match the criteria.

Apply to each 2 traverses the collection of items returned by Get items. If the body returned by Get items is empty, the action in Apply to each 2 will not be executed.

4.PNG

So there will be a situation you mentioned, you could check if the Body of Get items action is empty.

 

In addition, if the logic is to update the items filtered by Filter Query, the conditions configured in Condition seem to determine whether the collection returned by Get items is empty.

Like:

5.PNG

 

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.
CameronTCD
Level: Powered On

Re: My 'Update SharePoint Item' within an 'Apply to Each' doesn't run

Hi @v-bacao-msft 

 

The 'get items' will always only gather one result. The only reason I can't use 'get item' is that the ID is not known. I use the filter query to filter it down to the list item that I'm looking for (the filter phrase is provided in the forms trigger.)

 

Further, the condition looks at a reply from forms: 

>>>

'Does the supplied data satify your needs?' then continues on from a Yes/No answer depending on the input received.

>>>

 

I want the resultant answer to result in an update of that sharepoint item to either mark the open/close column as required.

Community Support Team
Community Support Team

Re: My 'Update SharePoint Item' within an 'Apply to Each' doesn't run

Hi @CameronTCD ,

 

Anyway, I think using Get items action is correct, I just analyzed why Update item action was not executed.

No eligible items are filtered out, so the Apply to each 2 action will not be executed because Body of Get items action is empty.

As for the content you configure in Condition, you can decide for yourself, they are not the reason why Update item action is not executed.

 

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.

Helpful resources

Announcements
firstImage

Microsoft Business Applications Virtual Launch Event

Watch the event on demand for an in-depth look at the new innovations across Dynamics 365 and the Microsoft Power Platform.

firstImage

Watch Sessions On Demand!

Continue your learning in our online communities.

Power Platform 2019 Release Wave 2 Plan

Power Platform 2019 Release Wave 2 Plan

Features releasing from October 2019 through March 2020.

thirdimage

Flow Community User Group Member Badge

Fill out a quick form to claim your user group badge now!

fifthimage

Microsoft Learn

Learn how to build the business apps that you need.

sixthImage

Power Platform World Tour

Find out where you can attend!

seventhimage

Webinars & Video Gallery

Watch & learn from the Flow Community Video Gallery!

Top Kudoed Authors
Users Online
Currently online: 110 members 3,005 guests
Please welcome our newest community members: