Skip to Content
0
Former Member
May 08, 2006 at 11:32 AM

SORT FUNC

17 Views

i made this comma

SORT lt_lbkum BY werks ASCENDING lgort ASCENDING matnr ASCENDING .

loop at lt_lbkum.

AT END OF matnr.

READ TABLE lt_lbkum INDEX sy-tabix.

i_lbkum-werks = 'X'.

i_lbkum-lgort = lt_lbkum-lgort.

i_lbkum-matnr = lt_lbkum-matnr.

i_lbkum-lbkum = lt_lbkum-lbkum.

i_lbkum-bwart = lt_lbkum-bwart.

APPEND i_lbkum.

CLEAR i_lbkum.

ENDAT.

ENDLOOP.

and i get a lot of rows when i need to get only 1 row becuse the werks is 1000 al the time