Application Development Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 

RFC with non sap system (UTF8)

Former Member
0 Kudos

Dear SDN members,

At my current project we are preparing for an upgrade and unicode conversion of our SAP landscape. I read in several SAP documents that the application servers will be UTF16 when you activate Unicode. Most of our third party systems are UTF8.

Is it possible to communicate from SAP (UTF16) to our third party systems (UTF 8)? In SM59 i can only find an option to say if the system is unicode or not, i don't see an option for the unicode version.

Best regards,

Victor

3 REPLIES 3

sunny_pahuja2
Active Contributor
0 Kudos

Hi,

Check SAP Note 647495 - RFC for Unicode ./. non-Unicode Connections

Which states as below:

UTF-8 partner calling Unicode system:

starting with kernel patches

620: 1329 (2004-2)

640: 3 (2004-2, PatchRq 565488-2004)

and in newer releases, the Unicode system uses UTF-8 for incoming RFC calls for all languages.

(Previously the default non-Unicode code pages listed above were used).

This change affects RFC applications running with UTF-8 encoding, in particular the UTF-8 SAP Unicode GUI. The SAP code page number for UTF-8 is 4110.

Thanks

Sunny

0 Kudos

I read note 647495 - RFC for Unicode ./. non-Unicode Connections but that only is about Unicode / non unicode RFCu2019s. In our case we have a Unicode (utf16) / Unicode (utf8) RFC. In note 1021459 they are talking about UTF16 for RFC calls. Does anybody know how the UTF16 / UTF8 conversion works in SAP for RFC connection?

Regards.

Victor

Edited by: Victor van Iren on Feb 22, 2010 12:52 PM

Former Member
0 Kudos

Hi Victor,

The Unicode encoding UTF-8 is equivalent to UTF-16, so there is a one-to-one mapping between the two (so no conversion issues and possible lost characters when converting from Unicode to a non-Unicode codepage). Conversion between the Unicode formats should be automatically handled by the RFC library. If your SAP application server (with the UTF-16 as you remarked correctly) is the RFC client, make sure though to mark the Unicode radiobutton in the RFC destination for your external RFC server.

As an example here a Unicode RFC server using JCo3 that I'm using, where the following excerpt shows some values from JCoAttributes of the JCoServerContext:


OWN_CODEPAGE:          4102
OWN_CHARSET:           UTF16
OWN_ENCODING:          utf-16
OWN_BYTES_PER_CHAR:    2
PARTNER_CODEPAGE:      4103
PARTNER_CHARSET:       UTF16
PARTNER_ENCODING:      utf-16
PARNER_BYTES_PER_CHAR: 2

Here you can see that my JCo3 RFC server is using codepage 4102 (UTF-16 with big endian), whereas the SAP application server uses code page 4103 (UTF-16 with little endian). Conversion between those two representations works fine.

You can also check [OSS note 1021459|https://service.sap.com/sap/support/notes/1021459], which gives some further hints for ensuring that the correct codepage is selected and the conversion works.

Cheers, harald