UpdateListItems bulk insert

Dec 3, 2013 at 11:51 PM
Is there a way to bulk insert multiple items in one UpdateListItems call?

I have a simple form that I'm letting users create multiple items at a time, then on submit, I want to take each of those entries and create a separate list item. Can I pass that in via the valuepairs somehow or do I need to roll my own batch command? It works currently iterating over each item, but it feels slow and clunky making multiple calls.
Dec 4, 2013 at 12:19 AM
Roll your own Batch CAML markup for the updates... You are also able to control if one failure causes the remainder of the updates to stop or to proceed with them... The return values from an update to multiple items will also tell you which ones failed and which were successful. and: you will definitely see an improvement on performance.

Paul T

Dec 4, 2013 at 12:41 AM
+1 on what Paul said. Build your own batches.

Dec 4, 2013 at 1:23 AM
Cool, wanted to make sure I wasn't missing something like being able to send in multiple arrays or something like that.

Sent from my iPhone

Dec 4, 2013 at 3:08 AM
The valuePairs thing was something I put in as a shortcut for quick stuff. It seems that a lot of people think that's how the operation works, but it's just my own shortcut. When in doubt, look at the underlying SDK docs.