Entering content frame

ABAP Development in Unicode Locate the document in its SAP Library structure

A Unicode-enabled ABAP program (UP)is one in which all Unicode checks are effective. Such a program returns the same results in a non-Unicode system (NUS) as in a Unicode system (US). In order to perform the relevant syntax checks, you must activate the Unicode flag in the screens of the program and class attributes.

In a US, you can only execute programs for which the Unicode flag is set. In future, the Unicode flag must be set for all SAP programs to enable them to run on a US. If the Unicode flag is set for a program, the syntax is checked and the program executed according to the rules described in this document, regardless of whether the system is a US or an NUS.  From now on, the Unicode flag must be set for all new programs and classes that are created.

If the Unicode flag is not set, a program can only be executed in an NUS. The syntactical and semantic changes described below do not apply to such programs. However, you can use all language extensions that have been introduced in the process of the conversion to Unicode.  

As a result of the modifications and restrictions associated with the Unicode flag, programs are generally executed in both US and NUS with the same semantics to a large degree. In rare cases, however, differences may occur. Programs that are designed to run on both systems therefore need to be tested on both platforms.

Recommendation

You are recommended to follow the procedure below to make your programs US-compliant:

·        First you should start the transaction uccheck in the NUS which determines the Unicode-relevant syntax errors for a small set of programs. If you need to determine syntax errors for a large set of programs, you can schedule a SAMT scan using the main program RSUNISCAN_FINAL and the subroutine SAMT_SEARCH.

·        Before you can set the Unicode flag in the NUS in the attributes of the program concerned, all syntax errors must be removed.

·        Once the Unicode flag has been enabled in the NUS, you can run the syntax check for this program. To display a maximum of 50 syntax errors simultaneously, choose Utilities -> Settings -> Editor in the ABAP Editor and select the corresponding checkbox.

·        Once all syntactical requirements are met in the NUS, you must test the program both in the NUS and US. The purpose of this test is to recognize any runtime errors and make sure that the results are correct in both systems. To prevent runtime errors in advance, you should always assign a type to field symbols and parameters, so that any problems can be picked up by the syntax check.

This graphic is explained in the accompanying text

 

 

 

Leaving content frame