ABAP MODIFY statement

In ABAP , MODIFY statement can be used with

  1. Database tables
  2. Internal tables
  3. Index tables
  4. Lists
  5. Screens

MODIFY statement is used for changing the current content value. Here you can see the usage & syntax of this statement with different scenarios.

Modify with database table

  • MODIFY <dbtab> FROM <wa>.

Here the database <dbtab> will adopt the new values from work area <wa>

  • MODIFY <dbtab> FROM TABLE <itab>.

Here the database <dbtab> will adopt the new values from an internal table <itab>

Modify with Internal table


Modify with Index table

MODIFY <itab> FROM <wa> [INDEX <idx>] [TRANSPORTING <f1> <f 2>…][ASSIGNING <FS> | REFERENCE INTO <dref>].

See the screenshot of a sample program here

Modify with lists

MODIFY LINE <n> [INDEX <idx>] [OF CURRENT PAGE|OF PAGE <p>]|CURRENT LINELINE FORMAT <option1> <option2>…FIELD VALUE <f1> [FROM <g1>] <f2> [FROM <g2>]…FIELD FORMAT <f1> <options1> <f2> <options2>.

Statement is used to change the specified line or last line of the current list.

See the screenshot for understanding the usage

Modify with SCREEN


See the sample program source code

Also Read : View Other ABAP Keywords & Syntax -> ABAP Transaction codes