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

Sort Internal table using "include" field

Former Member
0 Likes
476

Hi,

Hope someone can help me out. I have a transparent table with an .INCLUDE structure in it. My problems is, when i select records from that table and store it in an internal table then SORT it using one of the fields "included" (CDATE), i get an error saying:

"The specified type has no structure and therefore no component called "CDATE"".

My table and the included structure is Active.

Thanks, id really appreciate your help.

1 ACCEPTED SOLUTION
Read only

former_member194669
Active Contributor
0 Likes
427

Say for your table is like MARA that contains ZMARA as include contains CDATE

Then declare internal table as


data : begin of i_mara occurs 0.
   incldue structure mara.
data : end of i_mara.

then sort i_mara


sort i_mara by cdate.

Hi,

Hope someone can help me out. I have a transparent table with an .INCLUDE structure in it. My problems is, when i select records from that table and store it in an internal table then SORT it using one of the fields "included" (CDATE), i get an error saying:

"The specified type has no structure and therefore no component called "CDATE"".

My table and the included structure is Active.

Thanks, id really appreciate your help.

2 REPLIES 2
Read only

former_member194669
Active Contributor
0 Likes
428

Say for your table is like MARA that contains ZMARA as include contains CDATE

Then declare internal table as


data : begin of i_mara occurs 0.
   incldue structure mara.
data : end of i_mara.

then sort i_mara


sort i_mara by cdate.

Read only

0 Likes
427

Thanks a®s! you deserve the points!