on 05-16-2016 8:56 AM
Dear Experts,
Hope you are fine,
I have a problem, I need to map a field that is more than one, to the field that is just one, it is not possible to create a node with [0..n], so I want to know if there is any way I can do the mapping?
Thank a lot,
Sin
Hi Sin,
How do you want to map these multiple values from source payload to target??
Regards,
Praveen.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
HI
Use below UDF:
Execution Type: All Values Of Context
public void joinList(String[] list, ResultList result, Container container) throws StreamTransformationException{
String join = "";
for (int i = 0 ; i < list.length ; i++){
if (i!= 0)
join = join +";"+ list[i];
else
join = join + list[i];
}
result.addValue(join);
}
Use removeContext before UDF.
Regards,
Praveen.
Hi again Praveen,
I have another quetion hope you can help me about this,
I could get all the values if my target field,
But I have another problem. below you can see my idoc,
I have [0..n] E1KNVVM field, eachh of them have one TDID, and [0..n] TDLINE.
now I can send Z027, Z028, Z029 in my target, but I need to send the TDLine of each TDID to the target,
for example my targer should be like this:
PER QUALSIASI PROBLEMA IN FASE DI CONSEGNA CONTATTARE IL SIG. QUINTO AL N. 335/1989139 SI CHIUSO MARTEDI
Do you have any idea what exactly should I have to do?
Many Thanks
Sin
Hi Sin,
I meant, currently you are successfully sending the data of all the TDID fields into one target field consider field1 like below -
field1 = Z027, Z028, Z029
Do you want to send the data of TDLine into the same field? Below is the thing you are expecting or you want it in another field say field2?
field 1 = Z027, Z028, Z029 PER QUALSIASI PROBLEMA IN FASE DI CONSEGNA CONTATTARE IL SIG. QUINTO AL N. 335/1989139 SI CHIUSO MARTEDI
Regards,
Nitin
User | Count |
---|---|
84 | |
10 | |
9 | |
8 | |
6 | |
6 | |
6 | |
5 | |
3 | |
3 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.