cancel
Showing results for 
Search instead for 
Did you mean: 
newbie
Nintex Newbie

Create list items in bulk

Jump to solution

Hi guys,

I currently have a loop in my workflow for List A that looks through the repeater data in the form and creates list items in List B. Since this is a loop, it creates one item at a time in List B as it goes through this loop. 

Is there a way that the information from this loop can be saved and List B gets updated in one go, like mass update?

Thanks guys.

0 Kudos
Reply
3 Replies
Automation Master
Automation Master

Re: Create list items in bulk

Jump to solution

what's your primary concern? how fast items in listB are created or to reduce performance load/overhead on sharepoint?

 Since this is a loop, it creates one item at a time in List B as it goes through this loop. 

do you use simple 'Loop' action? it's quite slow due to save looping setting.

use 'For each loop' action, it's much faster.

Is there a way that the information from this loop can be saved and List B gets updated in one go, like mass update?

it's possible but not with OOTB nintex action. 

you'd need to make a direct call to Lists.asmx web service and its UpdateListItems method. that requires you to prepare a batch update XML request on your own. still batch size is limited to max 160 items

Lists.UpdateListItems Method (WebSvcLists) | Microsoft Docs 

if you'd like to avoid looping completely, you could use Query XML action and its XSLT transformation functionality. so within single action you could convert repeater XML into a webservice's batch update XML

Reply
newbie
Nintex Newbie

Re: Create list items in bulk

Jump to solution

Thanks for your reply Marian.

Yes you are correct, it was around performance load/overhead on sharepoint. You have given me few options, though am not too good with XML stuff, I shall try them out .

Reply
jpmhuls
Nintex Newbie

Re: Create list items in bulk

Jump to solution

Also keep in mind that the Loop action (behind the scenes) includes a pause with each iteration, slowing down the looping considerably. So maybe you can rework the loop into a Foreach..... but, because of the absence of a pause you may run into overloading the system with create new list item requests and you may have to include actions to pause every 20-30 itererations (store the Foreach index into a workflow variable, apply a MOD calculation and store the result in a different variable, e.g. varPauseNow, to be used in a Runif varPauseNow=0 AND index > 0 -just to avoid a pause at the start of the foreach- and which  contains a Pause for action).

0 Kudos
Reply