on 01-03-2014 5:40 PM
Hi experts,
Can you please help in UDF where I have two inputs, Field 1 and Field 2 each context may have values from 1 to many. I want output of Field 2 based on removing or suppressing how many values are there in Field1 context.
i.e;
attached in screenshot where field 1 i have only one value in context and field 2 i have three values so i want to eliminate or suppress first value in field 2
since the field 1 is having one value.
If field 1 is having two values in a context and field 2 has three values in a context then i want output as field 2 with last third value only.
Hi Prasad,
Did you check the node function OneAsMany ?
useOneAsMany (SAP Library - Partner Connectivity Kit)
Kind regards,
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Prasad.
Sorry for that.
But I dont follow you Prasad.
Input
<Field1>
<Value>1</Value>
</Field1>
<Field2>
<Value>1</Value>
<Value>2</Value>
<Value>3</Value>
</Field2>
Output must be:
<Field>
<Value>2</Value>
<Value>3</Value>
</Field>
Thats it, you need miss always the first value of xml file ?
Kind regards,
Hi Prasad,
Check the collapseContexts node function:
SAPTechnical.COM - Implementation of Node functions
I hope help this time.
Kind regards,
You can also do simple java mapping for this. Create one list for the field1 and second list for the field2. The third ouput list will do for loop to read the first list and check each content in the second list using another for loop and if matches don't add in the third list and if no match found then add it .
Basically you create java.list
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
85 | |
10 | |
10 | |
9 | |
7 | |
6 | |
5 | |
5 | |
4 | |
3 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.