cancel
Showing results for 
Search instead for 
Did you mean: 

Incorrect Quantities in custom analytical query

floydaus
Participant
0 Kudos

Hello,

I have created a query that displays a lot of SD information (sales order, outbound delivery, billing document etc.). However, the query does report the incorrect sales order quantities and outbound delivery quantities. See screenshot below. 

Incorrect Sales Order Qty censored.png

I used the following fields/elements in the query: I_SalesOrderItemCube.OrderQuantity and _I_OutboundDeliveryItem.ActualDeliveryQuantity. 

What is going on here? Can someone offer any help and/or solution?

Kind regards,

 

Floyd

 

View Entire Topic
TuncayKaraca
Active Contributor
0 Kudos

Hello Floyd,

I don't see Sales Order & Item Number in your screen shots. I would suggest you to focus one one a few specific Sales Order & Item Numbers examples and compare with the SAP S/4HANA system if you have access it.

I don't see any information about association _I_OutboundDeliveryItem here in Sales Order Item - Cube 

With Sales Orders and Outbound Deliveries there might be (1) partial delivery scenario - one sales order item can have multiple delivery items  (2) Deleted, canceled sales orders, items & delivery, items scenario

These two scenarios above should be considered. The partial delivery scenario will cause your sales order items measures double! 

Hope the information helps.

Regards,
Tuncay

floydaus
Participant
0 Kudos

Hello @TuncayKaraca,

Thank you for your quick reply. The above screenshots are from one sales order.

The CDS views I_OutboundDeliveryItem and I_SalesOrderItemCube have a Join Condition on the fields:

Join condition delivery.png

Furthermore, I check and there are no partial deliveries. Every individual sales order item is in the same delivery (e.g. all items from line 30 are in one delivery).

I see that some changes were made to the sales orders, but I do not understand how that could affect the sales order quantity in the query.

Lastly, why are sales order item measures doubled when there is a partial delivery? Is this a big from SAP?

I just want to see the quantity that is in my sales order to be displayed in my query.

floydaus
Participant
0 Kudos
Hello Tuncay,