ABAP Keyword Documentation → ABAP - Short Reference
INSERT itab - Short Reference
Other versions: 7.31 | 7.40 | 7.54
Syntax
INSERT { wa
| {INITIAL LINE}
| {LINES OF jtab [FROM idx1] [TO idx2] [USING KEY key_name|(name)]} }
INTO { {TABLE itab}
| {itab INDEX idx}
| {itab} }
[ {ASSIGNING <fs> [CASTING]} | {REFERENCE INTO dref} ].
Effect
Inserts lines into an internal table itab
.
Additions
-
wa
Inserts a work areawa
. -
INITIAL LINE
Inserts an initial line. -
LINES OF jtab [FROM idx1] [TO idx2] [USING KEY key_name|(name)]
Inserts the lines of the internal tablejtab
specified by the indices idx1 andidx2
, the table key to be used for this can be specified statically or dynamically. -
INTO TABLE itab
Specifies the insertion position using the primary table key. -
INTO itab INDEX idx
Specifies the insertion position using a table indexidx
. -
INTO itab
Specifies the insertion position in a loop using the current line. -
ASSIGNING <fs> [CASTING]
Assigns an inserted single line to a field symbol<fs>
, where casting can be performed. -
REFERENCE INTO dref
Assigns the reference to an inserted single line to a reference variabledref
.