Need someone's expertise and help please. i have a flow that will get the file from the sharepoint library to update the planner task details.
we have a planner task that is created daily (about 500 entries) and also a new files are created daily (about 500 entries).
the flow is to basically attached a link of the file to each task. the file properties is looking for:
then the file will find a match in the the planner then the file will get attached to the task
Now, the problem is, both get files and list task actions created an apply to each and running very very slow. the planner list task have 500 entries and the get files usually has 500 entries and this 500 entries most likely has a match in the list task planner.
is there a possible way to run the apply to each faster? i had it tested and it took 8hrs! and its not even done so i just canceled it. but looks like the flow works (i see the task getting the file attachment). i tried to use a filter array action hoping it would help to run faster but no luck.
Please help!!. see the copy of my flow below.
@abbyamante Loop inside loop always perform slow. But you can reduce api calls. Inside List Tasks Apply to each use Get file properties and then use filter query. Idea is to run list task loop 500 times but fetch only those file properties which matches filter query.
in Your case- you are applying loop 500 X500 means 2500 (normal single api calls) if you are using multiple action inside loop then each action will run 2500 times that's the reason your flow is slow.
Please 'Thumbs Up' the posts that helped you and 'Mark as Solution' if my post answered your question.
@Hardesh15 Hello! thank you for your response. It make sense but how can i implement that? the flow is creating the apply to each action automatically. Please kindly walk me through it how it can be done.
your help is greatly appreciated.
@abbyamante Please use in this way...i am using excel table
After get items if you use any dynamic content of it. it will apply loop but that loop will run only once if it found only one result.
Please 'Thumbs Up' the posts that helped you and 'Accept as Solution' if my post answered your question.