Skip to Content
0
Former Member
Jul 27, 2014 at 08:07 PM

Sales order : Creation of VBAP main lines from VBEP schedule lines

65 Views

Hello , I am working on SAP sales order interfacing with legacy system. This is the scenario where legacy system orders will come to SAP system for availability check. I mean , the legacy system sales order are replicalted in SAP system. and the availability check runs for it in APO.

Based on the SAP system stock availability , the sub item or sub items ( schedule lines) will be created in the sales order. Here is one example of partial quantity availability.Below example shows that sap system has received a order of quantity 100.

SAP stock available is only 20 for 29th may. Another quantity 80 will be available on 30th May.

So system will create two sub items or two schedule lines.

But when I save the sales order the sub-items lines should be converted into main item lines as shown in the below example in after save.

I tried this developement by using MV45AFZZ. User exit - SAVE_DOCUMENT_PREPARE. But I am not getting right results.

I short , I would like to have single schedule line for one item line. And if there are multiple schedlue lines then for each schedule line one item line should be created automatically by the system

Before Save Item Schedule line Req Date Req Qty Rounding Qty Confirmation Qty 40 1 29th May 100 100 20 2 30th May 80 After Save Item Schedule line Req Date Req Qty Rounding Qty Confirmation Qty 40 1 29th May 20 20 20 41 1 29th May 80 80 2 30th May 80