In Array and Out Array

Hi,
i have problem using the loop structure, here is my scenario,

Input side

i have document list as input and that list has another document list (i.e child of the first one). i have an element “x” in the child list (bear in mind “x” is not the only element present in the child list).

Output Side

The output side has also the same scenario as the input i.e a parent and child and child has an element called “y” ,

Now i need to map “x” to “y”, the input lists and output lists are not related to each other, so now can i have loop on the parent list of the input and have the out array as the parent list of the output…iam really struck up ,some one help me out ,please be elaborate
Thank you
apply

No…You have to loop on the child document list. Input array should be the child document list of your input document list and output array should be specified as the child document list of the output document list…

You may have to use the appendToDocumentList in package WMPublic as well, depending on exactly what you’re trying to do. Then you would create a single document in the form of your desired output, map stuff into it, and then append that document into the array in your output structure.

I believe you must use this approach if the list in the output structure has no elements before you start mapping into it.

Hello Apply,

You need two loops, nested as below

Outer Loop
In array : Parent loop (input)
Out Array : Parent loop (output)
Inner Loop
In array : Parent/Child loop (input)
Out Array : Parent/Child loop (output)
Mapping

Cheers !