cancel
Showing results for 
Search instead for 
Did you mean: 

Mapping an element from only the first source child node to target header element

former_member214137
Participant
0 Kudos

Hi,

I need some direction on how to properly implement this mapping.

I have a mapping source with header node and several children nodes and a target with a similar layout. I need to populate an element in the target header with the a value from an element in only the first source child.

In this case each line item in the source may be populated with a different business unit and I need to map the business unit from only the first line item from the source to the business unit in the target header.

regards

Julian

Accepted Solutions (1)

Accepted Solutions (1)

anupam_ghosh2
Active Contributor
0 Kudos

Hi Julian,

              you try this mapping

source element ---->removecontext (set context to point to source xml header node)--->copyvalue[0]------>target element

Regards

Anupam

former_member214137
Participant
0 Kudos

Hi Anupam,

Thanks for the quick response and answer.

Julian

Answers (1)

Answers (1)

rajasekhar_reddy14
Active Contributor
0 Kudos

Copy value standard function works in your case, try below mapping .

   input--copyvalue(0)------------->

              child note segment---->useoneAsMany---->Splitbyvalue(eachvalue)------>Traget field

              child note segment----->

If you have any difficulties paste your source structure.

former_member214137
Participant
0 Kudos

Hi Raja,

Thanks for the quick response and answer.

Julian