on 04-15-2011 6:19 PM
Hi Experts,
I have a scenario with a SOAP Sender adapter in XI 3.0 wich should receive a XML message from a legacy system.
This XML have the us-ascii encoding and we are not able to change it.
Our problem is that, when this message reaches the adapter, the XI is trying to change the encoding to UTF-8 (system default). After this conversion, the special characters in the message are not converted correctly. The result is a message with a lot of '?'.
We did try to follow the instructions from SAP note 856597 but the problem was not solved.
Any ideia about how to convert the incoming message to UTF-8 without losing these characters?
Any module we should use?
Check this PDF for different adapters:
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Even after these configurations characters like à and  are not correctly converted.
Those characters are not part of US-ASCII. So your input XML is corrupt.
There is no need to do a conversion from US-ASCII to UTF-8 as every character in US-ASCII has the same code in UTF-8.
But when you have characters which are not part of US-ASCII, then of course you cannot have a proper result.
When you say you cannot change this, then you are in a bad situation. You have invalid data and need to repair them before you continue.
The characters "ã" and "á" are stored in the database, once the system front-end shows them correctly.
If they are not supported, how are they stored?
Not the characters in the database are corrupt, but the XML.
When you have an XML header stating that the encoding is us-ascii, then no values are allowed which do not belong to US-ASCII.
So your XML should have encoding either ISO-8895-1 or UTF-8.
But you said you cannot change it, so you are lost.
maybe you show them this page from wikipedia:
http://en.wikipedia.org/wiki/ASCII
Standard for SOAP is using UTF-8 which includes any character.
So you should try to change the encoding at sender side.
Hi all,
Thanks for the help.
We changed the archtecture and now we are using JDBC. It solved our problem without extra configurations.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
The modules "AF Text Codepage Conversion Module" and "AF XML Anonymizer Module" also did not work for special characters.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
One solution is use java mapping and convert the incoming message to UTF-8 as below ..
try{
String string = "input string here";
byte[] utf8 = string.getBytes("UTF-8");
//The below line to convert into string
//String utfstring = new String(utf8);
}catch(Exception e){
}
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
84 | |
23 | |
11 | |
9 | |
8 | |
5 | |
5 | |
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.