Hey Everyone,
I’m having trouble updating multi-value lookup fields using workflows in SharePoint Designer 2013. I have approached this from two different angles (2010 workflows and 2013 workflows), but have not been successful using either method. The problems
I’m experiencing with each are different, as I’ll describe below, but the end goal here is the same, so I’d be thrilled if I could find a resolution to either issue.
Method 1 – SharePoint 2010 Workflow (Update list item)
This method looks like it should be relatively straight forward. I call a SharePoint 2010 workflow (or just running the workflow itself) and pass the appropriately formatted value (i.e. ID1;#;#ID2;#;#ID3) to the multi-value lookup field, but this has
been having mixed results.
On the library I’m needing to do this, some items update successfully while others do nothing. For example, I run the workflow on items 1 – 10. Items 3, 4, and 7 have their lookup field updated successfully, while the remainder do nothing.
The workflow runs successfully on all 10 items, no warnings or errors and nothing different happens in the ULS logs that I can determine. The items that update are consistent as well. If I deleted the values from 3, 4, and 7 and run the workflows
once more, 3, 4, and 7 will again update while the rest don’t. However, if I only pass one value (ID1), then the field updates successfully on all items. Other fields requiring only one value (text, lookups, etc.) have no issue updating appropriately.
That said, this issue only seems to be occurring in this one particular library thus far. I have not been able to reproduce this issue in other lists/libraries yet (I’ve admittedly only tried on a couple others). I’ve tried adding pauses, creating
new workflows from scratch, passing parameters, variables or hard-coding values – they all have the same outcome on this library. I can set multiple values if I manually do them, it’s just the workflow that’s failing to process this on some items.
Any insight as to why this might be occurring would be greatly appreciated.
Method 2 – SharePoint 2013 Workflow (POST web service call)
With Method 1 failing me, I decided to try updating the field via a POST web service call. Is this even possible? I don’t know how many hours I spent trying to make this work, but at this point I’m led to believe Designer workflows simply cannot
accomplish this. I can make it happen via other REST clients, but in Designer, it looks like the multi-value lookup field expects an array object which Designer itself is incapable of producing. Dictionary objects and string arrays don’t appear
to be sufficient no matter how I try to construct them.
I’d love to know if there’s some way to make this work.
Thanks,
Jordan