Ansicht
Dokumentation

ABENUNICODE_STRUCTURES - UNICODE STRUCTURES

ABENUNICODE_STRUCTURES - UNICODE STRUCTURES

BAL Application Log Documentation   PERFORM Short Reference  
This documentation is copyright by SAP AG.
SAP E-Book

Structure Enhancements and Unicode Programs

ABAP Dictionary structures and database tables that are delivered by SAP can be enhanced using customizing includes or append structures. These types of changes cause problems in Unicode programs if the enhancements change the Unicode fragment view.

For this reason, the option to classify structures and database tables was introduced, which makes it possible to recognize and handle problems related to structure enhancements. This classification is used during in the program check to create a warning at all points where the program works with structures, and where later structure enhancements can cause syntax errors or changes in program behavior. When you define a structure or a database table in ABAP Dictionary, you can specify the enhancement categories that are displayed in the following table as classification.

Level Category Meaning
1 Unclassified The structure does not have an enhancement category.
2 Cannot be enhanced The structure must not be enhanced.
3 Can be enhanced and character-like All structure components and their enhancements must be character-like and flat.
4 Can be enhanced and character-like or numeric All structure components and their enhancements must be flat.
5 Can be enhanced in any way All structure components and their enhancements can have any data type.

The warnings displayed after the program check are classified into three levels from the following table, depending on the consequences of the permitted structure enhacements.

Level Type of Check Meaning
A Syntax check An enhancement that fully utilizes the enhancement category of the structure in question leads to a syntax error.
B Extended check Permitted enhancements can lead to a syntax errors, but not always.
C Extended check Permitted enhancements cannot lead to syntax errors, although changes to program behavior do result in semantic problems.

Example

If the structure ddic_struc in ABAP Dictionary is defined only with flat components but is classified as Can be enhanced in any way, then the following program section leads to a warning in the syntax check. If the structure were to be enhanced by a deep component after the program was delivered, the program would be syntactically incorrect and no longer executable. This is why in this case you either have to classify the structure ddic_struc in ABAP Dictionary as Can be enhanced and character-like or else you cannot specify the offset/length in the program.

DATA: my_struc TYPE ddic_struc,
      str TYPE string,
      off  TYPE i,
      len TYPE i.
...
str = my_struc+off(len).






Fill RESBD Structure from EBP Component Structure   rdisp/max_wprun_time - Maximum work process run time  
This documentation is copyright by SAP AG.

Length: 4765 Date: 20240419 Time: 221903     sap01-206 ( 58 ms )