How to add repeatable list item data into XML data field


Badge +9

Hi Guys,

I tried to look for some example on how to add repeatable values (say, from editable list item data) into XML data-field in the context browser. Since data-field alone cannot save the repeatable value fields, we have to use xml datafield and I am wondering how could we accomplish this simple scenario.

I have a smartobject-view-form for editable list item as shown with fields like Account, Item destribution and Amount.

15033i112A3F1B4659D708.png

 

Now, when user take save action, these list item values should be saved in the xml data-field. Can someone please walk-through the process. It seems to be just a business rule implementation and mapping. Not sure how to do this. Thanks.


2 replies

Userlevel 1
Badge +8

Hi,

 

I wanted to take a step back and ask what the use case is for wanting to put this information in a process datafield?

 

The reason I ask is that you already have this data in an external source? It would be much easier to even just save selections from the list into a Smartbox smart object with some sort unifying identifier, pass that single value to the workflow then let the workflow retrieve the data from the smartobject when needed.

 

Storing a lot of data in the workflow isn't a best nor recommended practice. The rule of thumb is always give the workflow the least amount of data it needs to complete it's work.

 

I can help fill in the blanks on the direction I mentioned above, but wanted to understand your need as there are times you just need to have an XML structure for some reason. :)

 

S.

Badge +9

Hi Scott,

Thanks for your response. I understand and aware that using data-fields and xml data field in the process/activity data fields lowers the performance and definitely not the best practice. Thast why I saved all those list item values into the custom table with processinstanceid as unique identifier. I am just wondering how could we use this repeatable data fields values from smartform into the xml fields, unlike data fields which does not support the repeating data format. This is just to know-how to use the xml field to capture repeating data field values into the xml field in the workflow context. I tried to find some documents working on this, but could not find it. Just for learning purpose only.

Thanks.

Reply