SAP DATA RANGES ABAP Statements



Get Example source ABAP code based on a different SAP table
  


• RANGE OF DATA
• RANGE OF CLASS-DATA
• RANGE OF STATICS
• RANGE OF CONSTANTS

DATA, RANGE OF
Short Reference

ABAP_SYNTAX
DATA range_tab ${TYPE RANGE OF type$}$|${LIKE RANGE OF dobj$}
$[INITIAL SIZE n$]
$[VALUE IS INITIAL$]
$[READ-ONLY$].

What does it do?
This statement defines a ranges table range_tab with the table type described in the section TYPES - RANGE OF. The table type defined here, however, is not a standalone type, but exists as a property of the data object range_tab.
The addition VALUE IS INITIAL can be used to specify an initial start value.



Latest notes:

NON_V5_HINTS
Outside of classes, the addition WITH HEADER LINE can also be used to declare an obsolete header line.
The declaration of a ranges table using the statement RANGES is obsolete.
ABAP_HINT_END

ABAP_EXAMPLE_VX5
In this example, a ranges table is declared, filled, and evaluated in the WHERE condition of a SELECT statement.
ABEXA 00182
ABAP_EXAMPLE_END

Return to menu