Internal Table [DEFAULT] Expression

light111Internal Table [DEFAULT] Expression

SCARR table entries


While reading ITAB with key or index the DEFAULT expression can be added. In case the read is unsuccessful then the default value is assigned to the target value holder.


below here the s2nd read is unsuccessful, so the target  LS_SCARR2 is assigned to the default structure value.


DATA(ls_scarr_defVALUE scarrmandt symandt carrid ‘XX’ carrname ‘NOT ASSIGNED’  currcode ‘XXX’ url ‘NO URL’ ).

DATA(ls_scarr1VALUE #lt_scarr[ carrid ‘AA’ DEFAULT ls_scarr_def ).
DATA(ls_scarr2VALUE #lt_scarr[ carrid ‘ZZ’ DEFAULT ls_scarr_def ).


One comment

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s