on 06-01-2012 3:39 AM
Hi experts,
I've a scenario where I get different values in the queue with context change from the source and I have to map that to different target fields in the target...
The XSD from the source has one tag with occurrences 3..3 and the target XSD has three different fields...
My source XML looks like this:
<DTM>1</DTM>
<DTM>2</DTM>
<DTM>3</DTM>
My target XML looks like this:
<DTM1>1</DTM1>
<DTM2>2</DTM2>
<DTM3>3</DTM3>
Can you tell me how to solve this? Do I need an UDF or I can solve this with standard PI functionalities? If I need an UDF please provide me the java code...
Your help would be greatly appreciated,
Thank you in advance,
Hello,
You could use the predefined Constant function called copyValue e.g
DTM -> copyValue[0] -> DTM1
DTM -> copyValue[1] -> DTM2
DTM -> copyValue[2] -> DTM3
Hope this helps,
Mark
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi,
It all depends on the conditions. If the sequence is the key, you can use the function mendioned by Mark. If there are other conditions for putting values to fields, like value "1" always put to DTM1, no matter what is the sequence - then you can build a set of standard functions to meet your requirement.
Regards,
Greg
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
87 | |
10 | |
10 | |
10 | |
7 | |
6 | |
6 | |
5 | |
5 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.