05-11-2009 8:30 AM
My requirement is: I need to store the reference of each of the rows of a dynamic internal table(structure is determined only at the runtime) into a table.
Please throw some light on this to solve this proble.
05-11-2009 8:48 AM
DATA lp_data TYPE REF TO DATA.
DATA tr_reftable TYPE TABLE OF REF TO DATA.
LOOP AT <itab> ASSIGNING <ls_wa>.
GET REFERENCE OF <ls_wa> INTO lp_data.
INSERT lp_data INTO tr_reftable.
ENDLOOP
05-11-2009 8:46 AM
Hello,
You mean to say that u will get the structure at runtime.
We can get the table name if we get the table name it is easy?
Explain it clearly with simple example?
05-11-2009 8:48 AM
DATA lp_data TYPE REF TO DATA.
DATA tr_reftable TYPE TABLE OF REF TO DATA.
LOOP AT <itab> ASSIGNING <ls_wa>.
GET REFERENCE OF <ls_wa> INTO lp_data.
INSERT lp_data INTO tr_reftable.
ENDLOOP
05-11-2009 8:49 AM