inline declaration / value

REPORT ytest_value.

TYPESBEGIN OF ty_1,
         name TYPE string,
         role TYPE string,
       END OF ty_1.

DATA(wa1VALUE ty_1name 'sooraj'  role 'abap' ).

DATA(wa2VALUE #BASE wa1 name 'sachin'  role 'abaper' ).

cl_demo_output=>displaywa1 .


________________________________________________________________________

REPORT ytest_value.

TYPESBEGIN OF ty_1,
         name TYPE string,
         role TYPE string,
       END OF ty_1.
typestt_st1 TYPE TABLE OF ty_1 with DEFAULT KEY.

DATA(wa1VALUE tt_st1name 'sooraj'  role 'abap' )
name 'sooraj1'  role 'abap1' )
name 'sooraj1'  role 'abap1' )
name 'sooraj3'  role 'abap3' .


cl_demo_output=>displaywa1 .

Comments

Popular posts from this blog

sap abap import from excell to table (transparent table)

sap abap Import from excell to internal table that works 100%