on 11-14-2014 12:40 PM
Hello Alexander,
As per my understanding if your input file structure is as TestInput.xml and the expected output file structure is Test_Output.xml then you can get this output file (both the files are attached) as below:
Change the context of the field <ADDITXT> to the grand parent <E1WTADAL1>
write the udf taking the text field <ADDITXT> as input and the Execution type as Context..
String myOut="";
for(int i = 0; i< var1.length;i++){
myOut = myOut+var1[i];
}
result.addValue(myOut);
hope this will help.
Regards,
Suman
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi,
You can use the Concat function from Text group and map the required fields from Source to Target node.
Regards,
Azhar
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
now i get an Exception:
Exception:[com.sap.aii.mappingtool.tf7.FunctionException: Too many values in the second queue in function useOneAsMany. The number of values for all contexts must be the same as the number of values for the third queue] in class com.sap.aii.mappingtool.flib7.NodeFunctions method useOneAsMany[[Ljava.lang.String;@4f2db49d, [Ljava.lang.String;@41acd807, [Ljava.lang.String;@3a9ad540, com.sap.aii.mappingtool.tf7.rt.ResultListImpl@b267acf, com.sap.aii.mappingtool.tf7.rt.Context@b48b1c1]
See error logs for details
Check your useoneasmany function.
Follow the below wiki to understand the function and correct your mapping accordingly.
Hi Alex,
I can see you are sending same value to all the Target fields. If your UDF is generating correct String, just use "copyValue" function from Constant segment. Then the same value will be copied irrespective of the occurrence of the Target field.
But copyValue will work if you want pass the SAME value. Give a try.
UDF Output --> copyValue --> <temp_ABEZ>
Regards,
Nabendu.
User | Count |
---|---|
84 | |
10 | |
10 | |
10 | |
7 | |
6 | |
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.