on 11-07-2011 10:56 AM
Hi Group,
We have the below requirement,can any body help:
The incoming XML message needs to split based on 3 header fields combination (if any one of these changes needs to create new file) using Java mapping:
Source:
<?xml version="1.0" encoding="UTF-8"?>
<XML_DATA>
<Intdat>
<HEADER EMP = "EDNI,A,Aus"
</HEADER>
<Record>
<toi i1= "11"> </toi>
<toi i1= "12"> </toi>
<toi i1= "13"> </toi>
</Record>
</Intdata><Intdat>
<HEADER EMP = "PTA,A,US"
</HEADER>
<Record>
<toi i1= "21"> </toi>
<toi i1= "22"> </toi>
<toi i1= "23"> </toi>
</Record>
</Intdata>
<HEADER EMP = "EDNI,A,Aus"
</HEADER>
<Record>
<toi i1= "31"> </toi>
<toi i1= "32"> </toi>
<toi i1= "33"> </toi>
</Record>
</Intdata>
<HEADER EMP = "EDNI,B,Aus"
</HEADER>
<Record>
<toi i1= "41"> </toi>
<toi i1= "42"> </toi>
<toi i1= "43"> </toi>
</Record>
</Intdata>
<\XML_DATA>
Target:
Target File Name: EDNI_A_AUS.csv
EDNI,A,AUS,11,12,13
EDNI,A,AUS,31,32,33
Target File Name:PTA_A_US.csv
PTA,A,US,21,22,23
Target File name : EDNI_B_AUS.csv
EDNI,B,AUS,41,42,43
You need to build the following logic in your mapping -
Concatenate the keys field values within <Record> and compare the comination with other records.
If the combination is not same, then create message.
You can acheive this in graphical mapping using concat and SplitByValue(value change) functions.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi,
please go throuh below blog.
http://wiki.sdn.sap.com/wiki/display/XI/Multi-MappingusingJava+Mapping
i think with out java mapping we can do this, i am not sure,
Follow the below steps to achieve your requirement.
1. You need to provide occurance of the field to be 1..Unbounded.
2. Do the mapping according to the requirement.
3. In the Receiver Determination, you need to select " Extended" in the Type of Receeiver determination.
regards,
ganesh.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
81 | |
9 | |
9 | |
7 | |
7 | |
6 | |
6 | |
6 | |
5 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.