Application Development Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 

SD:Create Billing Wrt Inbound Deliveries - third party Order

Former Member
0 Kudos

Customer sends his Order forecast, From Interface it comes to SAP System through IDocs SO will be generated,that SO triggers purchase requistion and we have a batch job runs every hour to create purchase orders for Vendor. When the Vendor Sends goods to Customer and the same has notified to the Company, based on that we create Inbound Deliveries(VL31N) and Goods Receipt(MIGO or VL32N PGR) in our SAP System.

We have batch jobs running every hour to create Goods Receipt for inbound deliveries and Billing due(RV60SBAT) list to generate Billing documents.This Billing is created based on the sales order quantity(Since it is Order Related Billing).Now the Customer wants billing based on the delivery quantity they received from vendor.Here we are not doing any Outbound Delivery.

We used one Data Transfer Routine from Order to Billing in item category TAS at data VBRK/VBRP level(We copied the standard routine 003 and done modifications to get the inbound delivery no) This routine navigates from the sales document table(vbep) to the Purchase Requisition table(eban) to the Purchase Order history table (ekbe) and to the Material Document no to obtain Inbound Delivey Number

We are successful to some extent in creation of billing document.but the problem is when there are 3 inbound deliveries for one purchase order, it is creating only one invoice for 1 of 3 inbound deliveries.but we need 3 different invoices for 3 inbound deliveries.

For example

Previous scenario: SO quantity is 100. Delivey quantity is say 20,30,50. Billing Quantity is 100

Present scenario : SO quantity is 100. Delivey quantity is say 20,30,50. Billing Quantity is 20,30,50

Customer wants billing for the quantitiies 20,30,50 not for 100

2 REPLIES 2

Former Member
0 Kudos

I have moved your question to this forum as this might help you get a better response. Please remember there is no need to post your message multiple times.

Former Member
0 Kudos

Pradeep,

Whats is your billing qty based on Order- GR qty? or Order - Inbound delv qty. How did you get this?.

The problem lies because it is an order related billing.

Try this make it a Delv related billing w/o any movement type.

The moment you create an inbound delivery and O/P should be send which in turn will create a delivery document and PGI.(you can use this O/p type to do the dirty work)

And after this complex process life becomes simple.

Ravi