ABAP Keyword Documentation → ABAP - Reference → ABAP Syntax → ABAP Statements → Operands → Functions and Expressions in Operand Positions
Functions and Expressions for Operand Positions
Other versions: 7.31 | 7.40 | 7.54Writer Positions
Expressions that can be specified in writer positions are
... DATA(...) ...
... FIELD-SYMBOL(...) ...
- Table expressions
itab[ ... ]
and their chainings
Reader Positions
- Functions that can be specified in reader positions are
- Predefined functions
... func( arg ) ...
... func( val = arg p1 = arg1 p2 = arg2 ... ) ...
- Functional methods
... meth( ) ...
... meth( a ) ...
... meth( p1 = a1 p2 = a2 ... ) ...
... meth( [EXPORTING p1 = a1 p2 = a2 ...]
[IMPORTING p1 = a1 p2 = a2 ...]
[CHANGING p1 = a1 p2 = a2 ...] ) ...
- Method chaining
Chained method call:
... ...->meth1( ... )->meth2( ... )->...->meth( ... ) ...
Chained attribute access:
... ...->meth1( ... )->meth2( ... )->...->attr ...
- Expressions that can be specified in reader positions are
Calculation expressions:
- Arithmetic expressions
... arith_exp ...
- Bit expressions
... bit_exp ...
- String expressions
... string_exp ...
Notes
- Functions with numeric return values and arithmetic expressions are combined in numeric expressions.
- Functions with character-like return values and string expressions are combined as character-like expressions.
- Functions with a byte-like return values and bit expressions are combined as byte-like expressions.
Example
Numeric expression as an index specified for an internal table.
DATA: itab TYPE STANDARD TABLE OF i,
wa LIKE LINE OF itab,
n TYPE i.
...
READ TABLE itab INDEX lines( itab ) - n
INTO wa.