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

split line itab

Former Member
0 Likes
764

Hi all,

I have internal tbale itab, how to spit line of itab in one line with same key ( matnr)

 
2	0	0	32000212	2
1	0	0	32000213	1
1	0	0	32000214	1
1	0	0	32000215	1
1	0	1	32000215	2
3	0	0	32000216	3

record 32000215 must be 
1	0	1	32000215	2

7 REPLIES 7
Read only

former_member191735
Active Contributor
0 Likes
738

Loop at itab and use at new matnr or at change of matnr then move it to new table or structure based on your requirement.

Read only

SuhaSaha
Product and Topic Expert
Product and Topic Expert
0 Likes
738

Hello,

May be if you can specify how you want to output the internal table it will help in better interpretation.

If you want to download, a suggestion might be to create another table of type STRING. And proceed accordingly.

BR,

Suhas

Read only

Former Member
0 Likes
738

it is tipical ALV display.

Read only

SuhaSaha
Product and Topic Expert
Product and Topic Expert
0 Likes
738

Hello Nick,

Then we have a case in hand. Can you please be more specific when you want to split, i mean on what conditions?

BR,

Suhas

Read only

Former Member
0 Likes
738

in case that matnr is same in two lines as in example above

it should be one line

Read only

Former Member
0 Likes
738

But which one? the last one?

Anyway u need to check the internal table before showing it by ALV and delete the records having the material code

Max

Read only

Former Member
0 Likes
738

solved

must check all entries before output.