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

Accessing fields of a deep structure

Hi

I have a deep ( complex ) structure whose structure is as follows :

A ( Structure )

B ( A field of Structure A , B itself is a structure too )

C ( is a field of Structure B , contains two fields D & E )

D & E are fields of structure C and are table types

Now in the OO context, I am trying to implement a method - the above deep structure is an import parameter to the method and I am trying to access the fields of table types D& E .

To access the fields of D & E, I try to go like - A-B-C-D-fieldname - I get an error in the OO context - saying that D is not recognized...

Any idea how do I access the fields on the tabletype given above within this deep structure ? Is this something specific to the OO context ??

Thank you in advance for your time.

Add a comment
10|10000 characters needed characters exceeded

Related questions

1 Answer

  • author's profile photo Former Member
    Former Member
    Posted on Nov 22, 2005 at 12:16 AM

    Hi,

    Let us represent the structure A in OO Context.

    data:

    begin of SC,

    D type table of SD,

    E type table of SE,

    end of SC.

    (or)

    begin of SC,

    D type TD, "TD is of table type with structure SD

    E type TE, "TD is of table type with structure SE

    end of SC.

    data:

    begin of SA,

    SB,

    C type table of SC, (or C type TC)

    end of SA.

    data: TA like table of SA.

    Loop at A into SA.

    (SA-C-D is a table now)

    Loop at SA-C-D into SD.

    Endloop.

    (or)

    TD = SA-C-D.

    Loop at TD into SD.

    Endloop.

    Loop at SA-C-E into SE.

    Endloop.

    Endloop.

    Hope this helps,

    Bhanu

    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.