Application Development and Automation 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: 
Read only

SET LOCALE LANGUAGE space

Former Member
0 Likes
1,000

Hello together,

i'm having a problem with SY-LANGU in remote function calls.

If i call a RFC from a 3rd-party system i get SY-LANGU with the entry 'D'. That's very strange because i have maintained the language 'E' in my user profile.

So i changed SY-LANGU to 'E' at the beginning of my function module. No good style, i know...

But deep in the system, there is the following coding:

*   translate DESCRIPTION_UC to UPPER CASE
*   that is necessarry to use the field 'description_uc' in search helps
  cs_orderadm_h_wrk-description_uc = cs_orderadm_h_wrk-description
.

  SET LOCALE LANGUAGE cs_orderadm_h_wrk-descr_language.
  TRANSLATE cs_orderadm_h_wrk-description_uc TO UPPER CASE.
  SET LOCALE LANGUAGE space.

This coding sets the language to 'D', again.

I found the following explanation for the part with 'space':

"The special form SET LOCALE LANGUAGE SPACE (or lg contains SPACE) resets the text environment to the language of the active user as specified in the user master record."

I understand the function of this coding, but not the result. If i check SY-UNAME i get my user, so everything works fine.

Do you have any idea about this strange behaviour?

Best regards,

Sascha

Hello together,

i'm having a problem with SY-LANGU in remote function calls.

If i call a RFC from a 3rd-party system i get SY-LANGU with the entry 'D'. That's very strange because i have maintained the language 'E' in my user profile.

So i changed SY-LANGU to 'E' at the beginning of my function module. No good style, i know...

But deep in the system, there is the following coding:

*   translate DESCRIPTION_UC to UPPER CASE
*   that is necessarry to use the field 'description_uc' in search helps
  cs_orderadm_h_wrk-description_uc = cs_orderadm_h_wrk-description
.

  SET LOCALE LANGUAGE cs_orderadm_h_wrk-descr_language.
  TRANSLATE cs_orderadm_h_wrk-description_uc TO UPPER CASE.
  SET LOCALE LANGUAGE space.

This coding sets the language to 'D', again.

I found the following explanation for the part with 'space':

"The special form SET LOCALE LANGUAGE SPACE (or lg contains SPACE) resets the text environment to the language of the active user as specified in the user master record."

I understand the function of this coding, but not the result. If i check SY-UNAME i get my user, so everything works fine.

Do you have any idea about this strange behaviour?

Best regards,

Sascha

2 REPLIES 2
Read only

Former Member
0 Likes
667

Hi,

Check the language in the RFC destination.

Martin

Read only

0 Likes
667

Hello Martin,

thanks for your message.

Do i need an rfc destination in SM59 if i come from a 3rd-party system?

But if that's possible, it would not solve our problem. Because we need the user language (SU01) as standard language and not the language of a rfc-connection.

Can i change this?

Best regards,

Sascha