cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Highlighted
Helper V
Helper V

How can I bulk update a SharePoint list with specific values in a collection without delegation issues?

I have a collection containing changes to a SharePoint list that I want to patch en masse to my list. I am considered delegation is going to be problem.

 

Here is a sample of the Items list:

 

IDNameItemStatus
1BillMarketing0
2JaneAccounting1
3MarkIT1


My colChanges collection is as follows:

IDNameItemStatus
1BillMarketing2
3MarkIT2

 

I want to patch the changes to the Status column to the Items SP list simultaneously. I know I'll need ForAll and Patch, but I cannot figure out how to do it without running into delegation issues.

5 REPLIES 5
Highlighted
Super User III
Super User III

@pwrappr01 

Will this work?

ForAll(
  colChanges,
  Patch(your_items_list, LookUp(your_items_list ,ID=colChanges[@ID]), {Status: colChanges[@Status])
)

 

---
Please click "Accept as Solution" if my post answered your question so that others may find it more quickly. If you found this post helpful consider giving it a "Thumbs Up."

Highlighted

@mdevaney, thanks for responding. Unfortunately, no because that creates a delegation warning that hampers the functionality of the patch due to SharePoint not currently supporting certain actions on the native ID column. 

Highlighted

@pwrappr01 
If the ID field cannot be delegated then the best way to perform a bulk update might be sending the Collection to MS Flow and having it perform the update. 

 

---
Please click "Accept as Solution" if my post answered your question so that others may find it more quickly. If you found this post helpful consider giving it a "Thumbs Up."

Highlighted

I like the way you think. I'll do it that way. Hoping a native Power Apps solution becomes available soon. Thanks for your help!

Highlighted

@pwrappr01 

I too would enjoy a native PowerApps solution.  I prefer to use as few Flows as possible when building a PowerApp (low-flow LOL) so I am always looking for a workaround.

 

---
Please click "Accept as Solution" if my post answered your question so that others may find it more quickly. If you found this post helpful consider giving it a "Thumbs Up."

Helpful resources

Announcements
Community Conference

Power Platform Community Conference

Check out the on demand sessions that are available now!

News & Announcements

Community Blog

Stay up tp date on the latest blogs and activities in the community News & Announcements.

secondImage

Power Platform 2020 release wave 2 plan

Features releasing from October 2020 through March 2021

Community Highlights

Community Highlights

Check out the Power Platform Community Highlights

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