‎2006 Nov 02 6:10 AM
DATA : is_data type mara.
FIELD-SYMBOLS:<fs_data> type ANY.
MOVE CORRESPONDING <fs_data> to is_data.
this statement works in ERP 2005 but not in ERP 4.6C
Can any one tell me what is the smilar statement for this in ERP 4.6C
‎2006 Nov 02 8:33 AM
Hi Lokesh,
can you be a bit elaborative with the problem.
what i can see is you defined a field symbol of type any, so you will need to assign this field symbol to a field of mara and then you can use the direct assignment.
Eg:
DATA : is_data type mara.
FIELD-SYMBOLS:<fs_data> type ANY.
assign is_data-matnr to <fs_data>.
<fs_data> = 500.
move <fs_data> to is_data.
write is_data-matnr.
or if you are using the field symbol as a structure then the following example works
DATA : is_data type mara.
FIELD-SYMBOLS:<fs_data> structure mara default is_data.
<fs_data>-mandt = 800.
<fs_data>-matnr = 500.
move <fs_data> to is_data.
write: is_data-matnr,
is_data-mandt.
hope this helps.
Regards,
Kinshuk
‎2006 Nov 02 9:30 AM
hi,
use:
do.
assign component sy-index of structure <fs_data> to <f1>.
assign component sy-index of structure is_data to <f2>.
if sy-subrc = 0. move <f1> to <f2>. endif.
...A.