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

Multiple "Update item" actions

I have a flow that "When item create or mofified" on the first SP list, it creates 30 new items or updates all 30 items on the second SP list.

On the YES side, I have 30 "Create item" actions. One "Create item" action follow by another "Create item" action and so on. No problem here.

On the NO side, I also have 30 "Update item" actions just like the YES side.

I have no problem with the condition, it seems to recognize when to create or update.

The porblem is actually on the NO side. All 30 items updates using data from the first item. It doesn't move to the next items. I am using "Get items" for each "update item" action with Filter query to single it out. So I should have 30 "Get item" actions in the NO side now. Is there a better way to do this? This is a waste of time.
1 ACCEPTED SOLUTION

Accepted Solutions
Highlighted
Community Support
Community Support

Re: Multiple "Update item" actions

Hi @Melio ,

 

Could you share a screenshot of your flow?

 

It seems that you would like to copy item from List1 to List2, it the item is already exists in List2, update it, otherwise, create a new one in List2.

 

If my understanding is correct, instead of using 30 Create item and Update item actions, please take a try with the following flow.

 

When an item is created or modified in List11, triggers the flow.

 

Initialize an Array variable named as Test.

 

Get items from List33 (the destination list).

 

Add Apply to each, get value from List33, add Append to array variable within Apply to each, set its value as Title from List33.

 

Add a Condition to check if the array variable Test contains the item from the trigger.

 

If yes, which means that it is an existing item, we need to add Condition 2 to filter out the specific one to update it.

 

If no, which means that it is a new item, use action Create item to create a new one in List33.

 

Images for your reference:

1.PNG2.PNG

 

Best regards,

Mabel

 

Community Support Team _ Mabel Mao
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

2 REPLIES 2
Highlighted
Super User II
Super User II

Re: Multiple "Update item" actions

If you could provide an expanded screenshot of your Flow and steps, and of any detailed error messages you're receiving we could likely better assist you.

If this reply has answered your question or solved your issue, please mark this question as answered. Answered questions helps users in the future who may have the same issue or question quickly find a resolution via search. If you liked my response, please consider giving it a thumbs up. THANKS!

Highlighted
Community Support
Community Support

Re: Multiple "Update item" actions

Hi @Melio ,

 

Could you share a screenshot of your flow?

 

It seems that you would like to copy item from List1 to List2, it the item is already exists in List2, update it, otherwise, create a new one in List2.

 

If my understanding is correct, instead of using 30 Create item and Update item actions, please take a try with the following flow.

 

When an item is created or modified in List11, triggers the flow.

 

Initialize an Array variable named as Test.

 

Get items from List33 (the destination list).

 

Add Apply to each, get value from List33, add Append to array variable within Apply to each, set its value as Title from List33.

 

Add a Condition to check if the array variable Test contains the item from the trigger.

 

If yes, which means that it is an existing item, we need to add Condition 2 to filter out the specific one to update it.

 

If no, which means that it is a new item, use action Create item to create a new one in List33.

 

Images for your reference:

1.PNG2.PNG

 

Best regards,

Mabel

 

Community Support Team _ Mabel Mao
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

Helpful resources

Announcements
firstImage

Super User Program Update

Three Super User rank tiers have been launched!

firstImage

Power Platform 2020 release wave 2 plan

Features releasing from October 2020 through March 2021

firstImage

New & Improved Power Automate Community Cookbook

We've updated and improved the layout and uploading format of the Power Automate Cookbook!

thirdimage

Power Automate Community User Group Member Badge

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

Top Solution Authors
Top Kudoed Authors
Users online (9,065)