21.2.11

SAP Note 22886 - Collective slip to provision SC components WL83

Symptom:

Key word: Output determination, goods receipt/issue slip, output type WLB3
On a collective slip for the provision of components (subcontracting), each component is printed twice.

Cause and prerequisites

For each component, two material document items are created with movement type 541. However, only one item should be taken into account when printing.

Solution
Insert the line marked "new" below in program M07DRAUS:
FORM LESEN_WLBS USING OBJKY.
NAST_KEY = OBJKY.
CLEAR RETCO.
PERFORM OPEN_FORM_SAMMEL.
ZAEHLER_M = 1.
SELECT SINGLE * FROM MKPF WHERE MBLNR = NAST_KEY-MBLNR
AND MJAHR = NAST_KEY-MJAHR.
SELECT * FROM MSEG WHERE MBLNR = MKPF-MBLNR
AND MJAHR = MKPF-MJAHR.
CHECK MSEG-SOBKZ IS INITIAL. "new ==========> insert
IF SY-SUBRC NE 0.
...
ENDFORM.

No comments:

Post a Comment