on 08-28-2009 10:41 PM
Hi All,
I have a conditional mapping requirement in the graphical mapping.that i have a two nodes in source side both are identical. Each node has corresponding sub elements. Target side i have node with subelements.Based on the below conditions I need to map corespnding source node to the target.
Condition1: IF LINE items node value is 'contracts.LineItem' in the source structure then map corresponsing target Line item node and its line item fields.
Condition2: If Line item node value is not 'contracts.LineItem' and if CATALOG_ID field is not populated and IF "/MT_FCI_CONTRACT_EXPORT/fcidataexport/objects/object/extensions/collection/@name" node value is 'MATGRP_COLLN' then only map corresponding source node 'ROW' to the target Line Item node and its fields.
I have achieved condition1, by having duplicating target Line Item node and mapping first condition source node. Please help me how to achive mapping in the secod condition.
Thanks in advance.
Regards,
Rajesh
+Condition2: If Line item node value is not 'contracts.LineItem' and if CATALOG_ID field is not populated and +
+IF "/MT_FCI_CONTRACT_EXPORT/fcidataexport/objects/object/extensions/collection/@name" node value is 'MATGRP_COLLN' +
then only map corresponding source node 'ROW' to the target Line Item node and its fields.
LineItem ---->
------> equalS---> Not -->
Constant(contracts.LineItem)-->
--------->And1(o/p from Not)
CATALOG_ID---->
------> equalS---> Not -->
Constant(keep blank)-->
---------->And2(o/p from And1 and equalS)--->IfWithoutElse->Target
@name---> (Then-->ROW)
--->equalS--->
Constant(MATGRP_COLLN)--->
You will need to take care of Context of the source nodes, since you will be having multiple occurences of them.
Regards,
Abhishek.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Rajesh,
It seems you can achieve your functionality using standrd if else functions. To get the exact mapping can you give us the source and target structures and an example payload, which would be more easy to understnad and also sombody can help you out by looking at them.
Regards,
---Satish
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Rajesh,
This is can be very easily achieved using UDF. Pass the node value / field value in the UDF as argument and do a check there.
If the UDF returns a true, then use the createIf function to map.
Hope this helps. Let us know if you have more questions.
Regards,
Neetesh
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
94 | |
11 | |
10 | |
9 | |
9 | |
7 | |
6 | |
5 | |
4 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.