Skip to Content
author's profile photo Former Member
Former Member

Internal table

Hello everybody,

i have a problem!!

I think that i can not find the solution because i am so bad in developing code!

I need to create an internal table in a dynamic way.

Now i will explain my real problem !!

I developing a bsp page, i need to extract some HR data from r/3 via RFC i have a function "HR_READ_INFOTYPE" that returns me all the information in a char line without a structure (no problem), i extract from dd03l table the structure of the relative infotype (note: i can extract more data from different infotype) when i come back to the Web AS system i need to create at runtime the n internal table with the exact structure for each infotypes that i have extracted . So is tit possible to create dynamicly an internal table having the structure in another internal table?!?

Thanks a lot !!!!


Add a comment
10|10000 characters needed characters exceeded

Related questions

1 Answer

  • Best Answer
    Posted on Oct 16, 2003 at 11:40 AM


    you can construct a new internal table with a given line type with the following syntax:

    DATA dref TYPE REF TO data.

    CREATE DATA dref { {TYPE tabkind OF {type|(name)}}

    | {LIKE tabkind OF dobj} }

    [WITH key]


    The dynamic creation of new structures will be available with Release 6.40.

    Example for creating an internal table with a given structure:

    PARAMETERS: dbtab(10) TYPE c,

    rows TYPE i DEFAULT 100.

    DATA dref TYPE REF TO data.








    CATCH cx_sy_create_data_error.

    WRITE 'Wrong Database!'.




    Add a comment
    10|10000 characters needed characters exceeded

Before answering

You should only submit an answer when you are proposing a solution to the poster's problem. If you want the poster to clarify the question or provide more information, please leave a comment instead, requesting additional details. When answering, please include specifics, such as step-by-step instructions, context for the solution, and links to useful resources. Also, please make sure that you answer complies with our Rules of Engagement.
You must be Logged in to submit an answer.

Up to 10 attachments (including images) can be used with a maximum of 1.0 MB each and 10.5 MB total.