cancel
Showing results for 
Search instead for 
Did you mean: 

Schedule line delivered quantity in query

Former Member
0 Kudos

I'm not 100% sure on where to post this question as this could be considered SD and PP.

We currently use a custom program that has been in place for many years to list our sales documents by periods/months, weeks etc.  Due to the bugs that exist in this program, I have recently attempted to create a query capable of producing the same results with partial success.  The only issue that we are struggling with is the situation of part delivered schedule lines.  In the below example, the first schedule line has 7 pieces already delivered meaning that the remaining quantity we need is actually 338.  The "delivered quantity" for a schedule line is actively calculated through a structure therefore I am struggling to get this value into the query.

Sales DocCustomerItemSchLnMaterialQtyGBP ValueGBP CostGBP Cont
50001Customer 100100001ABCD34512,420.00
0002ABCD541,944.00

VBEP-WMENG = Order quantity

VBEP-CMENG = Rounded qty

VBEP-BMENG = Confirmed qty.

VBEPD-VSMNG = Delivered qty

Does anyone know of a solution?

Thanks in advance,

Dan

Accepted Solutions (1)

Accepted Solutions (1)

Lakshmipathi
Active Contributor
0 Kudos

Though couple of standard reports are there to show the open order quantity and value, since you said that some customized report is running for several years which you are trying to fine tune, you can consider the below logic

Order Quantity (VBEP-WMENG) less Delivered Quantity (LIPS-LFIMG) = Open Quantity (VBBE-OMENG) * KONP-KBETR is your open order value

G. Lakshmipathi

Former Member
0 Kudos

Thanks for the help!  VBBE-OMENG is the field I need.  That will work perfectly!

Regards,

Dan

Former Member
0 Kudos

I've hit another slight snag if someone could enlighten me...  I have added the VBBE table to the query to use the OMENG field as above, however for some reason not all sales orders are present in this table; orders that definitely exist in VBEP, VBAP etc.  Is anybody aware why only certain orders exist?

Added:

This thread seems to explain it: http://scn.sap.com/thread/3203850

The issue this causes for us is that we need to be able to see even those orders that do not exist in VBBE.  Even if a sales order item does not have a planning requirement, we still need to display it.  Even if an order item does not have a planning requirement, to my knowledge it is still possible to partly deliver and invoice it by percentage.  Is this information not available within a table?

The report basically need to determine if statements.  If the order is in VBBE then display VBBE-OMENG otherwise look at xxxx-xxxxx.  Even with the calculated fields within a query, I'm pretty sure this will be impossible as the order will need to be present in both tables for the query to even consider it.  Correct?

Message was edited by: Daniel Barnes

Lakshmipathi
Active Contributor
0 Kudos
Even if an order item does not have a planning requirement, to my knowledge it is still possible to partly deliver and invoice it by percentage

Can you explain with an example from your clients' Business perspective?  Without passing on the planning requirement as to what material / components needs to be produced, how SAP will consider the order quantity and pass on the information to production team ?  Incidentally, apart from VBBE, VBBS table also will show open quantity provided, the material is set to 01 as Availability Check.

G. Lakshmipathi

Former Member
0 Kudos

Ok I'll try to clear this up a bit.  In this example, line 10 is of type CT as it represents a maintenance service to be carried out using the items below it.  All the other lines are of type CP and represent manufactured materials.  Because L10 does not have any requirements, it is not present in VBBE.  Therefore using the table VBBE with the query means that this document cannot be viewed.

Essentially the query needs to be able to list all of the VBEP schedule lines with a specific date range but also include fields from VBAP, VBUP, VBAK and KNA1 - all of which work successfully within a query:


It then also needs to include the "open quantity" (VBBE-OMENG) even if it is not a manufactured item.  Even though L10 is a service with a quantity of 1, often a delivery note and invoice are created of a percentage of the work (e.g. 0.5 if the service is half complete).

So...

Is there a table that contains the "open quantity" regardless of type of schedule line?

Failing that, is there at least a table that would contain the "open quantity" for the service lines that could be used in addition to VBBE?  Although this would inevitably mean moving away from a query to bespoke ABAP work.

Regards,

Dan

Lakshmipathi
Active Contributor
0 Kudos
Even though L10 is a service with a quantity of 1, often a delivery note and invoice are created of a percentage of the work 


I am not sure, why you were creating delivery for Service related item.  Ideally,  the process should have been order related billing in which case, straightaway, you can consider VBAP-KWMENG less VBRP-FKIMG.  In your case, you need to adopt this logic to your line item 10.

G. Lakshmipathi

Answers (0)