MB_CREATE_GOODS_MOVEMENT now with subcontracting



This is a technical Release info for customers who use this function module in their own programs.

As of Release 4.0A, you can assign purchase order items with item category 3 (subcontracting) to the MB_CREATE_GOODS_MOVEMENT function module.

The function module automatically generates the output table items for the input table items. In this case, there is no 1:1 relationship between the tables IMSEG and EMSEG.

In your own programs which use the MB_CREATE_GOODS_MOVEMENT function, you must ensure that the assignment of IMSEG to EMSEG is correct. These are assigned using the EMSEG-TABIX field by displaying this field on the corresponding IMSEG entry.

See the following example:


1 - GR f. SC ( has 2 components )
2 - GR normal to warehouse
3 - GR f. SC ( has 3 components )


1 1
1 1 2
1 2 3
2 4
3 5
3 1 6
3 2 7
3 3 8

The lines with EMSEG-AZEIL not equal to zero were generated automatically. EMSEG-TABIX specifies the IMSEG entry to which this EMSEG-ZEILE belongs.

What happens if an error occurs?

Error in the GR item:

Error in the GI item:

Das gleiche Szenario gilt auch, wenn mit den Bewegungsarten 102 und 122 gearbeitet wird.

Anders verhält es sich, wenn die Bewegung zur LB-Position mit em MB_CANCEL_GOODS_MOVEMENT storniert werden soll. Hier ist wieder eine 1:1-Beziehung zwischen IMSEG und EMSEG gegeben, da die IMSEG bzw. EMSEG aus dem Materialbeleg aufgebaut werden (in dem die WA-Zeilen enthalten sind). D. h. hier steht auch die WA-Zeile in der IMSEG.

Der Storno darf generell nur gebucht werden, wenn kein Fehler auftritt.