Application Development and Automation 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: 
Read only

can we include tables in structures

Former Member
0 Likes
949

Hi

Structures r defined in the same way as tables and i read that for structures database table is not generated.

A table can contain a structure.

Hence same data elements and domains can be used both in structures and tables,So is it possible to include the tables in structures.

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
921

Hi,

Not possible.

Structure means a single record skeleton, table means multiple records holder, how can you insert table in structure. It may take as structure itself, even if you include.

Regards,

Anji

Hi

Structures r defined in the same way as tables and i read that for structures database table is not generated.

A table can contain a structure.

Hence same data elements and domains can be used both in structures and tables,So is it possible to include the tables in structures.

7 REPLIES 7
Read only

Former Member
0 Likes
922

Hi,

Not possible.

Structure means a single record skeleton, table means multiple records holder, how can you insert table in structure. It may take as structure itself, even if you include.

Regards,

Anji

Read only

Former Member
0 Likes
921

Hello Nirmala,

Yes it is possible. U can do like .include -- MARA for a structure Ztest.

Not the stu. Ztest will ahve th structure of mara but no data.

Thanks!!

Vasanth

Read only

0 Likes
921

hi,

u mean that if v include table in struc, table-struct wil be included not the data,

and wat abt including struc to the existing table which hav records...

Read only

Former Member
0 Likes
921

yes u can include a table structure into ur structure not the values.

Read only

Former Member
0 Likes
921

it is not possible to include the table inside the structure.. if it is possible.. then the property of structure is meaning less.

Regards,

Sujatha.

Read only

Former Member
0 Likes
921

Hi,

Yes u can include a table but in the datatype u will find it as STRU means structure u won't get the values in that.U can Try to include but it won't act as a table since a structure is a flat data type where as table is a tree structured data type.If u want that u can go for deep tables.

Regards,

Ravi

Read only

Former Member
0 Likes
921

Hi, You can include a table in structure like:

DATA: BEGIN OF ls_record.

INCLUDE STRUCTURE mara.

DATA: END OF ls_record.

Regards,

Balakrishna.N