Skip to Content

Archived discussions are read-only. Learn more about SAP Q&A

how to move data in the field symbol to table

field symbol <it_mara> is having few records

and there is a work area <wa_mara>

now i have a table it_abc and work area wa_abc, with different structure ,but has some comman fields in it_mara.

how can i transfer the records in <it_mara> to the corresponding fields of table it_abc ?

table it_abc is not field symbol.its declared as table

Tags:
replied

Hi, try like this:

Option 1.

FIELD-SYMBOLS: <AUX_FIELD> TYPE ANY.
ASSIGN COMPONENT 'YOUR_FIELD' OF STRUCTURE <wa_mara> TO <AUX_FIELD>.
wa_abc-YOUR_FIELD = <AUX_FIELD>.

Option 2.

DATA: ls_field type string.
FIELD-SYMBOLS: <AUX_FIELD> TYPE ANY.

MOVE '<wa_mara>-YOUR_FIELD' TO ls_field.
ASSIGN (ls_field) TO <AUX_FIELD>.
wa_abc-YOUR_FIELD = <AUX_FIELD>.

In case the Table <it_mara> has a define structure you can simple do:

wa_abc-YOUR_FIELD = <wa_mara>-YOUR_FIELD.

Bye, Andrew83.

Edited by: Andrew83 on Sep 15, 2008 4:18 PM

0 View this answer in context
Not what you were looking for? View more on this topic or Ask a question