on 12-02-2011 10:08 AM
Hi ,
I have scenario, where in mapping I need to have a condition.. where the fields are not mandatory.
Below is the my Source XML:
<?xml version="1.0" encoding="UTF-8" ?>
<INVENTORYINTERFACE>
<DOCUMENT>
<SAPFUNCTIONALITY>CONSUMPTION</SAPFUNCTIONALITY>
<BLDAT>07.29.2011</BLDAT>
<BUDAT>07.29.2011</BUDAT>
<FileName>test.xml</FileName>
<MATERIALDATA>
<MATNR>1000000000</MATNR>
<BATCHDATA>
<CHARG>123456789</CHARG>
<WERKS>1000</WERKS>
<ERFMG>186.10</ERFMG>
<ERFME>KG</ERFME>
<ID>1</ID>
<FLAG>Y</FLAG>
</BATCHDATA>
</MATERIALDATA>
</DOCUMENT>
</INVENTORYINTERFACE>
Here if ID or Flag is not there then I need to process.
And If ID exists then I need to check for the Flagexistsa or not... if any of then is missing then I need to fail the mapping
How can I do so?
Hi Hareen,
id -> exits(true) -> constant(true) -> equals ->if (then)-> check -> exits -> constant(true) -> equals -> target msg
thanks,
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
hi,
first u dont write ur logic ,
u try this
1.id -> 2.exits(true) -> 3.constant(true) -> 4.equals ->5.(first)if (then)
-> 6.check -> 7.exits -> 8.constant(true) -> 9. equals -> 10.(second)if -> target
if Check fail (second)(if) then -> constant -> target msg
if Id fail (first )if-else ->constant -> target
thanks,
User | Count |
---|---|
76 | |
9 | |
8 | |
7 | |
6 | |
5 | |
5 | |
5 | |
5 | |
5 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.