cancel
Showing results for 
Search instead for 
Did you mean: 

need help in graphical mapping

Former Member
0 Kudos

Hi gurus,

we have following input message type

<ROOT>

     <ITEM>

         <ID>A</ID>

         <LIST>

             <NR>101</NR>

             <NR>102</NR>

         </LIST>

     </ITEM>

     <ITEM>

         <ID>A</ID>

         <LIST>

         </LIST>

     </ITEM>

     <ITEM>

         <ID>A</ID>

         <LIST>

             <NR>103</NR>

         </LIST>

     </ITEM>

         <ITEM>

         <ID>A</ID>

         <LIST>

             <NR>104</NR>

         </LIST>

     </ITEM>

     <ITEM>

         <ID>B</ID>

         <LIST>

             <NR>201</NR>

         </LIST>

     </ITEM>

     <ITEM>

         <ID>B</ID>

         <LIST>

             <NR>202</NR>

             <NR>203</NR>

             <NR>204</NR>

         </LIST>

     </ITEM>

</ROOT>

and need the following output ;

<ROOT>

     <NODE>

         <ID>A</ID>

         <NR>101</NR>

     </NODE>

     <NODE>

         <ID>A</ID>

         <NR>102</NR>

     </NODE>

     <NODE>

         <ID>A</ID>

         <NR>103</NR>

     </NODE>

     <NODE>

         <ID>A</ID>

         <NR>104</NR>

     </NODE>

     <NODE>

         <ID>B</ID>

         <NR>201</NR>

     </NODE>

     <NODE>

         <ID>B</ID>

         <NR>202</NR>

     </NODE>

     <NODE>

         <ID>B</ID>

         <NR>203</NR>

     </NODE>

     <NODE>

         <ID>B</ID>

         <NR>204</NR>

     </NODE>

</ROOT>


in some of case is the list without <NR>

     <ITEM>

         <ID>A</ID>

         <LIST>

         </LIST>

     </ITEM>

How can we solve this mapping issue with graphical mapping?

Thank you


Accepted Solutions (1)

Accepted Solutions (1)

former_member190624
Active Contributor
0 Kudos

Hi Peter ,

Amrish mapping will handle only one ID (i.e. ID node should not occurrence should not be more than 1(to use one as many) ). I think , we can achieve this requirement by java mapping easily .

Regards

Hari.

ambrish_mishra
Active Contributor
0 Kudos

Hi Hari,

I normally don't give a solution on graphical maps without testing.

here are some screenshots:

Test case given by Peter and the results below:

Hope it helps!

Ambrish

Former Member
0 Kudos

Thank you Ambrish,

can you tell me, what is the context of NR?

ambrish_mishra
Active Contributor
0 Kudos

Hi,

if you are talking about Node mapping, it is root (s in my case)

Ambrish

Answers (1)

Answers (1)

ambrish_mishra
Active Contributor
0 Kudos

Hi Peter,

Here is your solution:

Mapping for Node and NR.

Context of NR is root.

Mapping for ID. Context of NR is ITEM. context for ID is ITEM.

Hope it answers your question.

Ambrish

added screenshots again... Message was edited by: Ambrish Mishra