Skip to Content
Feb 13, 2020 at 01:38 PM

Codepage UTF-16 to UTF-8 problems


Dear all,

we receive messages via IDOC. The user we are using for connection has codepage 4103 (UTF-16le) maintained.
This could unfortunately not simply be switched to 4110 (UTF-8).

One IDOC has as content a string which has next to whitspaces (HEX Code 20) also Non-breaking spaces (HEX Code A0).
In SAP PO this seems to be saved as UTF-8 which would be C2 A0 for Non-breaking space.
But in outputfile he seems to read it byte by byte and wrotes an  for the C2 byte.

Non-Breaking in Hex Code:

UTF 16: 00A0
UTF 8 : C2 A0
Output in file : C2 (Â)

How can I handle this that the output file does not contain  signs, but keeps this Non-breaking spaces?
Do I have to convert the incoming file? If so, do you have a best-practice (XSTL, Java, module,..)?