Application Development Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 

moving field symbol(internal table containing data ) to internal table

Former Member
0 Kudos

HI,

How to convert Field symbol (which is an internal table) into an internal table.

The fields FS are being populated dynamicall hence the structure

is not fix so will be that of the desired internal table.

REGARDS

SIVA

2 REPLIES 2

Sandeep_Kumar
Product and Topic Expert
Product and Topic Expert
0 Kudos

Declare another field symbol like :

field-sy,bols : <tab> type any table.

assign component of ur field symbols to this structure one by one.

Former Member
0 Kudos

Hi Siva,

I don't really understand what it is you want to do but you might want to read the SAP help about field smbols: [http://help.sap.com/saphelp_nw04/helpdata/en/fc/eb3860358411d1829f0000e829fbfe/content.htm]

As is written there, "field symbols are placeholders or symbolic names for other fields". They cannot be internal tables or be "converted" into internal tables, but the can point to internal tables. If what you're trying to do is moving the contents of an internal table with a dynamic structure, dyn_itab1, pointed to by a field symbol, <fs1>, into another internal table you might want to try this:


data dyn_itab2 type any table.
field-symbols <fs2> type any table.
create data dyn_itab2 like <fs1>.
assign dyn_itab2->* to <fs2>.
<fs2> = <fs1>.

Best regards,

Erik