Ansicht
Dokumentation
ABAPDATA_STRUC - DATA STRUC
Vendor Master (General Section) TXBHW - Original Tax Base Amount in Local CurrencyThis documentation is copyright by SAP AG.
DATA, BEGIN OF struc
DATA BEGIN OF struc $[READ-ONLY$].
...
INCLUDE TYPE$|STRUCTURE ...
...
DATA END OF struc.
Effect
Declaration of a new structure struc. This is introduced using a DATA statement with the addition BEGIN OF and must end with a DATA statement with the addition END OF.
The following can be included between these DATA statements:
- Any DATA statements, particularly further closed structures.
- The statements INCLUDE TYPE and INCLUDE STRUCTURE
The meaning of these statements is the same as in the definition of structured data types in the section TYPES - BEGIN OF. However, here it is used to create a bound structured data type. No structure can be created without at least one component.
A component of struc cannot be declared by referencing struc itself. If the name struc
is specified after LIKE in the declaration of a component, a search is performed for the next object with this name in a higher
visibility section and used if found. If there is no more global object with this name, a syntax error occurs.
Notes
- The addition READ-ONLY is only possible for the entire structure, not for individual structure components comp.
- A structure called text cannot have any components with three-character names, since these are reserved for addressing text symbols. It is best to never call a structure text to avoid any conflicts with text symbols.
- The addition BOXED cannot be specified between DATA BEGIN OF and DATA END OF when declaring components. Static boxes in structures can only be defined with TYPES.
- The value operator VALUE can be used to construct the content of structures.
- In an obsolete variant, text field literals or the constant space can be specified as anonymous components between BEGIN OF and END OF.
- The use of the addition OCCURS for defining standard tables with structured line types is obsolete.
- The statements for declaring a structure are usually summarized in a chained statement if possible.
Example
In this example, a structure spfli_struc is declared with an elementary component index and a substructure spfli_wa. The SELECT loop shows a possible use of the nested structure.
RFUMSV00 - Advance Return for Tax on Sales/Purchases Fill RESBD Structure from EBP Component Structure
This documentation is copyright by SAP AG.
Length: 4900 Date: 20240329 Time: 082807 sap01-206 ( 69 ms )