2008 Dec 26 9:44 AM
I am creating a dynamic internal table where in i have to enter another table. the structure of table is decided by a fieldcatlog of type LVC_S_FCAT.
i want to know which field has to be filled which will identify the table.
<<text removed by moderator>>
Edited by: Matt on Dec 27, 2008 12:56 PM
I am creating a dynamic internal table where in i have to enter another table. the structure of table is decided by a fieldcatlog of type LVC_S_FCAT.
i want to know which field has to be filled which will identify the table.
<<text removed by moderator>>
Edited by: Matt on Dec 27, 2008 12:56 PM
2008 Dec 26 11:24 AM
2008 Dec 26 11:42 AM
hi Aveek,
i know to create a simple internal table
its about creating an internal table inside an internal table.
like :
data: BEGIN OF INTERNALTABLE,
........................
table1 TYPE <some table type>
END OF INTERNALTABLE.
2008 Dec 26 11:58 AM
2008 Dec 26 12:03 PM
hi aveek,
u have gave me the link to create internal table statically.
how can i do the same (including a table into a internal table) dynamically...
thanks for reply.
2008 Dec 26 12:30 PM
2008 Dec 26 12:37 PM
hi Aveek,
i understand the concept of internal table in internal table,
the point is how can i acheive it at runtime.... that is while i create a dynamic internal table.....
2008 Dec 27 12:03 PM
Assuming you've got an outer table something like this:
field1
field2
field3
inner_table TYPE TABLE OF...Instead, define it like this:
field1
field2
field3
p_inner TYPE REF TO dataCreate your inner table dynamically. Then, where WA is your workarea for the outer table ( i.e. you READ and INSERT using wa ) use
GET REFERENCE OF <inner_table> INTO wa-p_inner. " Puts inner table into the outer workarea
* or
ASSIGN wa-p_inner->* TO <inner_table>. " Gets inner table from outer workarea.Instead of storing the inner table within the outer table, you are storing a reference (the memory location) of the inner table.
matt
2008 Dec 26 12:52 PM
| User | Count |
|---|---|
| 3 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 |