Application Development 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: 

not able to display the values on the alv report.

Former Member
0 Kudos

Hi all,

loop at it_stpo.

indx = sy-tabix.

select single bdmng from resb into it_resb-bdmng

where matnr = it_stpo-idnrk

and xloek ne 'X'.

it_stpo-bdmng = it_resb-bdmng.

modify it_stpo index indx.

endloop.

in the above code, m fetchin the values of bdmng and populating it in the it_stpo.

the values get populated in the internal table.

But the problem is only the first value of all the entries gets populated.

For ex:

it_stpo-idnrk = C0201AA0800N ** under this components der r three entries***

i want to display all three values of these entries.

1.A0201AD6750N 990

2.A0201AJ0960N 1,578

3.A0201AJ1140N 2,996

but the value 990 gets repeated thrice for the above three entries. n the value 1598 n 2996 is not gettin displayed.

lll, for all other entries. only the first entry value gets displayed for their respective components.

suggest modification in my code so dat i cn display all the values.

thanks in advance.

regards,

purva.

5 REPLIES 5

Former Member
0 Kudos

hi,

As u are using the select single though there are the 3 entries for that idrnk u are getting only the value and your internal table is getting populated with 900. if you require all the values for the idrnk then pass whole key and get the values.

Reward points if find useful

Former Member
0 Kudos

I think the work area is not getting cleared

clear: it_resb-bdmng

check if this statement is creating problems.

Reward if useful

Former Member
0 Kudos

i faced same pro dont use sy-tabix,,,

use some variable as counter and try

0 Kudos

Hi all,

select bdmng from resb into corresponding fields of table it_stpo2

for all entries in it_stpo

where matnr = it_stpo-idnrk

and xloek ne 'X'.

loop at it_stpo2.

move-corresponding it_stpo2 to it_stpo.

append it_stpo.

endloop.

In the above code, m able to fetch the records in the table it_stpo2. but the data is not gettin populated in the final internal table it_stpo. Both the internal tables it_stpo & it_stpo2 are same.

The data is gettin moved from it_stpo2 to it_stpo but only upto the header level. its not gettin appended in the table it_stpo even after using append stmt.

Plz help me to resolve this issue. its urgent.

Rgds,

Purva

0 Kudos

Thank u al.

i got d logic for the same n i got the desired output.

My issue has been resolved.