Skip to Content
0
Former Member
Jun 28, 2007 at 07:16 PM

Help with collect statement

12 Views

Hi,

I have the following code involving collect:

SORT I_ZDAILY_MVMT BY MATNR WERKS.

LOOP AT I_ZDAILY_MVMT.

AT END OF MATNR.

SUM.

COLLECT I_ZDAILY_MVMT INTO I_OUTPUT_CHECK.

ENDAT.

ENDLOOP.

Say I_ZDAILY_MVMT contains 4 records. All this does is sends 1 record at each loop, until I_OUTPUT_CHECK is filled with the same 4 records and no sum.

How do i fix this?

Thanks,

John