Ansicht
Dokumentation

ABENLOGEXP_RULES_OPERANDS_STRUC - LOGEXP RULES OPERANDS STRUC

ABENLOGEXP_RULES_OPERANDS_STRUC - LOGEXP RULES OPERANDS STRUC

General Data in Customer Master   General Data in Customer Master  
This documentation is copyright by SAP AG.
SAP E-Book

- Comparing Structures

It is possible to compare structures with structures and structures with elementary fields:

  • Compatible structures are compared component by component, whereby any nested structures are resolved recursively. Two structures are equal if the content of their components matches. In the case of unequal structures, the first unequal component pair determines the result of the comparison.
  • It is possible to compare incompatible structures and structures with elementary fields provided that the structures concerned are flat.
  • Comparisons between two flat structures require that their fragment views match for the length of the shorter structure. Before the comparison, the shorter structure is padded to the length of the longer structure. Here, all character-like components are padded with blanks and all other components with their type-dependent initial value. The comparison then takes place in stages according to the fragment view.

  • Comparisons between a flat structure and an elementary field are subject to the following rules:

If the flat structure is character-like, it is handled in the comparison as an elementary field of type c.
If the flat structure is not just character-like, the elementary field must have the type c and the first fragment of the structure fragment view must be character-like and at least as long as the elementary field. If the elementary field is shorter than the structure, it is extended to the length of the structure before the comparison and then handled implicitly like a structure. The character-like parts of the extension are padded with blanks and all other components are padded with their type-dependent initial value.

Example

The following comparison is true because the structure is handled like a field of type c with length 8.






General Data in Customer Master   Addresses (Business Address Services)  
This documentation is copyright by SAP AG.

Length: 2581 Date: 20240425 Time: 002357     sap01-206 ( 48 ms )