on 08-25-2010 2:01 AM
Hi ,
This is a File to SOAP scenario, where text file is picked by XI and posted to target using webservice in the xml format.In the message mapping, I am supposed perform a logic where 3 fields in the source structured are to be concatenated and sent to the target structure. This fields at the target structure are to be displayed with a newline character.
So if I am sending : abc, 123 and xyz as input and the output should be in one field as follows :
<ns3:OutputField xmlns:ns3=abc
123
xyz</ns3:StreetAddressLine>
I have used this "
" as the seperator in the concat function, hoping this would produce a new line but was hopeless.
Any ideas are appreicated.
Thanks,
Rag
Hi,
Target side when you see XML format then only you can see Newline not in Graphical way. Click on SRC icon
Use UDF like (here src1 and src2 are input argument and result is parameter of type string)
String temp1="";
temp1 = src1+ "\n";
result = temp1.concat(src2);
return result;
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Did you try to achieve that with Java or XSLT mapping?
It may be a restriction of message mapping.
BR,
Henrique.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Raghav,
XML will never show new line or space characters.
Try to open the message in notepad or wordpad and then check if you can see the new line character.
-Supriya.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi,
As an alternative I have used an UDF between the fields like this :
TargetString= (((Field1 + '\n') + Field2 + '\n') + Field3);
But the XML generated had a single concatenated string with no line feeds (new Lines).
Appreciate your inputs..
Thanks,
Rag
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 | |
9 | |
7 | |
6 | |
6 | |
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.