結構給結構賦值

REPORT ZSTRU01_2.
 data: begin of wa1,
       carrid type spfli-carrid value 'aa',
       connid type spfli-connid value '0017',
       fldate type d value '20090822',
       end of wa1.
      
 data wa2 like wa1.
 move wa1 to wa2.
 data: begin of wa2,
       carrid type spfli-carrid ,
       connid type spfli-connid ,
       name(8) type c,
       end of wa2.
 move wa1 to wa2.//wa1還是能全賦值,但是我們要對字段名相同的賦值,不同不賦值 move-corresponding wa1 to wa2.
 write wa2.
發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章