Learn how to prevent duplicate inter-company AR/AP postings when working with cross-company free-of-charge sales orders.
Key Concept
Inter-company journal postings are common when processing a cross-company business scenario. The SAP system automatically generates inter-company journal postings for you if you post a credit in one company and a debit in another company
In a typical cross-company sales order business process, a sales company makes a sale of goods to its customer and another company’s warehouse delivers the goods to that customer. I’ll discuss one cross-company scenario, a free-of-charge scenario, in which the SAP system generates duplicated inter-company AR/AP postings. A company might use a free-of-charge cross-company code sales order in a number of other scenarios, including when sending a free sample, providing compensation for a short shipment, or handling departmental expenses involving sending parts to a customer.
A number of different sales order scenarios result from such situations. I’ll discuss three possible sales order scenarios:
- Cross-company sales order scenario
- Single company free-of-charge sales order scenario
- Cross-company free-of-charge sales order scenario
I’ll then analyze why duplicated postings can occur and the related FI/CO configuration. Finally, I’ll present possible solutions, which prevent duplicated postings, in four different stages of the sales order:
- Sales order header
- Delivery order
- MM document for goods issue
- FI document for goods issue
You can apply the information in this article to both R/3 and SAP ERP Central Component (ECC) 6.0 systems.
Cross-Company Sales Order Scenario
In a standard SAP cross-company sales order scenario, a sales organization sells a material to its customer, drop shipping it directly from another company’s delivery plant. Because of this relationship, one sales order triggers both customer billing and inter-company billing (Figure 1). This scenario has become increasingly common because more multinational corporations are setting up centralized distribution centers in tax havens. A tax haven is a place where certain taxes are levied at a low rate or not at all. One of the most popular places to set up a centralized distribution center is Amsterdam because of its tax advantage and well-established logistics infrastructure.

Figure 1
A standard cross-company sales process
Let’s say a US manufacturer produces a product. If it sells the product directly to a German customer, then the entire profit is subject to US tax, and the product takes at least a week to reach the customer. However, the manufacturer can first sell the product to its Amsterdam centralized distribution center and then re-sell it from there to its German customer. Then, only the profit earned from the first sale is subject to US tax. In addition, this sales process is faster and the shipping is cheaper.
Single Company Free-of-Charge Sales Order Scenario
In a standard SAP system, there’s a free-of-charge sales order scenario in which a company delivers a material to its customer without billing the customer. The company then charges the cost for that material to a cost center. In this scenario, you need to enter an order reason at the sales order header. The system then automatically derives the cost center from the order reason. By specifying a different order reason, you can use it for reporting. In addition, you can assign a cost center to an order reason for free-of-charge sales order accounting. To assign the cost center to the order reason, follow configuration menu path SPRO > Sales and Distribution > Basic Functions > Account Assignment/Costing > Assign Cost Centers and use configuration table TVAUK.
Find the order reason and cost center in the sales order header by using transaction code VA03 or following menu path SAP menu > Logistics > Sales and Distribution > Sales > Order > VA03 - Display (Figure 2). In the sales order header, go to the Sales tab and you can see the Order reason field. Click on the display document header details icon
to get to the Sales tab in the Header Data screen. Then click on the Account assignment tab (Figure 3) and look at the Cost Center field. In this example, cost center 3200 is assigned to order reason 999.

Figure 2
Order reason data in the sales order header

Figure 3
Cost center data in the sales order header
Cross-Company Free-of-Charge Sales Order Scenario
When you process a typical cross-company sales order or a single company free-of-charge sales order, the SAP system behaves correctly in both cases. However, you might have come across a scenario in which your company needs to process both a cross-company sales order and a free-of-charge sales order together. In my example, the US sales organization delivers a product to its German customer free of charge, drop shipping it directly from the Amsterdam distribution center (Figure 4). In this scenario, at the goods issue, the system debits from the cost of sales and credits to the inventory in the Amsterdam delivery plant company. At inter-company billing, the system debits from the inter-company AR and credits to the inter-company revenue in the Amsterdam delivery plant company. In the US sales organization company, the system debits from the operating expense with cost center and credits to the inter-company AP (Table 1).
Goods issue | Dr COS (standard price) Cr inventory | N/A | Inter-company billing | Dr I/C AR (transfer price) Cr I/C revenue | Dr operating expense with cost center Cr I/C AP | |
Table 1 | Expected postings for cross-company free-of-charge sales |

Figure 4
Cross-company free-of-charge sales process
However, in FI and Controlling (CO), if you post to a cost center that belongs to another company, the SAP system triggers the inter-company AR and AP postings automatically. Consequently, the accounting entries result in the following postings. At the goods issue, the system debits from the inter-company AR and credits to the inventory in the Amsterdam delivery plant company. In the US sales organization company, the system debits from the cost of sales with cost center and credits the inter-company AP. At inter-company billing, the posting is the same as the expected postings that I previously mentioned (Table 2).
Goods issue | Dr I/C AR (standard price) Cr inventory | Dr COS with the cost center Cr I/C AP | Inter-company billing | Dr I/C AR (transfer price) Cr I/C revenue | Dr Operating expense with cost center Cr I/C AP | |
Table 2 | Actual postings for cross-company free-of-charge sales |
Many SAP users and consultants don’t fully understand inter-company journal postings. Figures 5 and 6 show two typical inter-company journal voucher screens. You can display these screens by using transaction code FB03 or following menu path SAP menu > Accounting > Financial Accounting > General Ledger > Document > FB03 - Display. The Cross- CC no. field for these two journal vouchers in company codes 002 and 006 is the same, indicating that these two journal vouchers are a pair of automatically generated inter-company journal postings.

Figure 5
Typical inter-company journal voucher screen for company code 002

Figure 6
Typical inter-company journal voucher screen for company code 006
This situation presents a typical integration issue between Sales and Distribution (SD)/Materials Management (MM) and FI/CO. From a transactional SD and MM perspective, there’s no problem because the Amsterdam company correctly issues the material and the system correctly updates the inventory quantity and processes the delivery order. From a transactional FI and CO perspective, the system is simply performing according to SAP’s design. In my example, when posting to the US cost center in the Amsterdam company code, the SAP system balances the journal posting by automatically deriving the offsetting entry for inter-company AR and AP. However, when looking at the process from a broader and higher level, the final posting is not correct for the following reasons:
- For the Amsterdam delivery plant company code, the system posts the inter-company AR twice — once at the goods issue according to the standard price and once at the inter-company billing according to the transfer price. The cost of sales is missing from the whole process.
- For the US sales organization company code, the system posts the inter-company AP twice — once at the goods issue according to the standard price and once when booking the inter-company AP according to the transfer price. The system also posts charges to the cost center twice — once at the goods issue according to the standard price and once when booking the inter-company AP according to the transfer price.
To understand why these duplicated postings occur, you need to know more about automatic inter-company AR/AP postings’ configuration.
Configuration of Automatic Inter-Company AR/AP Postings
In FI, when posting to the US cost center in the Amsterdam company, the SAP system automatically connects the postings between the two companies. This means that if the credit is at the Amsterdam delivery plant company and the debit is at the US sales organization company, the SAP system automatically proposes the offsetting entries to keep the double entries balanced per company. Debiting the inter-company AR is the offsetting entry for crediting the inventory in the Amsterdam delivery plant company. Similarly, crediting the inter-company AP is the offsetting entry for debiting the cost of sales in the US sales organization company. To enable this process, you need to have set up the following configurations.
In CO, you should select cross-company code cost accounting by following configuration menu path SPRO > Controlling > General Controlling > Organization > Maintain Controlling Area > Maintain Controlling Area. In the CoCd-CO Area field, select 2 Cross-company-code cost accounting. This setting enables multiple company code assignments to one single Controlling area.
As a prerequisite to this configuration, you should ensure that the CoCd Validation check box in CO is already checked by following menu path SPRO > Controlling > General Controlling > Organization > Maintain Controlling Area > Maintain Controlling Area > Activate components/control indicators. Having this check box checked means that one cost center can only be used in one company and makes the SAP system automatically propose the inter-company AR and AP postings.
In FI, you can set up the inter-company clearing account by using transaction code OBYA or following menu path SPRO > Financial Accounting (New) > General Ledger Accounting (New) > Business Transactions > Prepare Cross-Company Code Transactions (Figure 7). The Debit posting key/Account debit and Credit posting key/Account credit fields display the posting key or account used for inter-company clearing. To enable your SAP system to automatically propose the inter-company AR and AP postings, you must define this configuration. Otherwise, your SAP system won’t know which inter-company account it should propose.

Figure 7
Configuration for the inter-company clearing account through transaction code OBYA
The previous configuration is commonly used. When the US cost center travels from the sales order header to the FI posting in the Amsterdam company, the SAP system automatically creates the inter-company journal voucher. Figure 8 presents a roadmap of the cost center’s journey from the order reason of the sales order to the FI document.

Figure 8
Cost center’s journey from the order reason to the FI document
Note
In a cross-company free-of-charge sales order, you should not pass the cost center to the FI document unless you’re charging to the delivery plant company’s cost center.
Prevent Duplicate Postings
As indicated in Figure 8, cost center information flows from the cost center assignment for the order reason, configuration table TVAUK, all the way to the FI document. To correct the problem, you need to stop the cost center from passing into the FI document for the cross-company free-of-charge sales order. Next, I’ll go over the four places in the flow of the cost center in which you can intervene to prevent duplicate postings: the sales order header, delivery order, MM document for goods issue, and FI document for goods issue.
1. Sales Order Header
When you’ve assigned a cost center to an order reason, the system updates this cost center automatically at the sales order header’s Account assignment tab (Figure 3).
At first glance, it might seem best to remove the cost center from this tab. However, this solution only works if you haven’t implemented Electronic Data Interchange (EDI), or Application Link Enabling, which allows for the automatic posting of the inter-company AP at the US sales organization company. If you have implemented EDI, however, I do not recommend doing this.
Although this action prevents the inter-company AR/AP posting from being duplicated, it causes problems for EDI because EDI needs the cost center to make the inter-company AP posting in the US sales organization company. If EDI cannot find the cost center information, the posting to the inter-company AP in the US sales organization company fails. This causes problems for inter-company reconciliation or the user might need to manually post the inter-company AP, which is time consuming and prone to input errors. Intervening at this stage is easy because changing the sales order header only requires user-level knowledge. However, it can also have an adverse impact on EDI.
2. Delivery Order
By stopping the flow of the cost center to the delivery order, you can still keep the cost center in the sales order header, which does not affect EDI. At the same time, the system won’t pass the cost center to the MM/FI document at the goods issue and thus won’t generate inter-company AR/AP postings.
Use the following three-step procedure to implement this fix:
Step 1. Identify the copy control. Follow configuration menu path SPRO > Logistics Execution > Shipping > Copying Control > Specify Copy Control for Deliveries… (Figure 9). Select the header copy control (i.e., the sales order to the delivery order types circled in Figure 9). Double-click on Item on the left side of the screen to bring up the Item: Overview screen (Figure 10). Examine the ItmCt column and identify which item copy control the system configured for that free-of-charge sales order type, which is circled in the figure.

Figure 9
Locate the header copy control for the free-of-charge sales order type

Figure 10
Identify the item copy control for the free-of-charge sales order type
Step 2. Create a customized copy routine. Next create a customized copy routine and use it to replace the existing copy routine shown in Figure 11. (Because creating a copy routine is more related to ABAP developers, I won’t go into further detail here.) In the Data Transfer section, replace the original copy routine in the Item data field with a customized copy routine. In my example, I have used the customized copy routine 699 to replace the original copy routine in the Item data field. Then click on the save icon.

Figure 11
Replace the standard copy routine with a customized copy routine
Step 3. Define the logic in the new customized copy routine. In the new customized copy routine, first run the original SAP standard copy routine. Next, check if it’s a cross-company sales order (i.e., the sales organization company differs from the delivery plant company). In my example, the US company differs from the Amsterdam company, so it is a cross-company sales order. Also see if the cost center company differs from the delivery plant company. In my example, the US cost center belongs to the US company, which differs from the Amsterdam company. If this is the case, clear the cost center value in the delivery order. As a result, the goods issue MM document does not inherit the cost center from the delivery order and thus the system doesn’t pass the cost center to the FI document.
Performing these steps won’t affect EDI. There’s also minimal configuration impact because the configuration change is specific and restricted to the free-of-charge sales order type only. There aren’t any specific disadvantages when using this method.
3. MM Document for Goods Issue
SAP Note 1133399 removes the cost center from the MM document if it’s coming from a cross-company sales order. However, this SAP Note has a limitation because it is a fix from a pure SD/MM perspective. The note’s logic always removes the cost center if the goods issue posting is coming from a cross-company sales order. However, this also results in the removal of the cost center even if the cost center to which you want to charge belongs to the Amsterdam delivery plant. In this situation, you shouldn’t remove the cost center. Because there’s no inter-company billing involved in this scenario, as seen in Figure 12, you should pass the cost center to the FI document, which results in the following posting. The accounting entry posted in the Amsterdam delivery plant company credits the inventory and debits the operating expense with the cost center. In the US sales organization company code, an accounting posting isn’t necessary (Table 3).
Goods issue | Dr operating expense with cost center (standard price) Cr inventory | N/A | Inter-company billing | N/A | N/A | |
Table 3 | Posting for free-of-charge cross-company sales charging to the delivery plant company |

Figure 12
Cross-company free-of-charge sales order charging to delivery plant’s cost center
To overcome this problem, the checking logic should be similar to that mentioned earlier in the “Delivery Order” section. Put in this extra and necessary piece of logic by using the Business Add In (BAdI) LE_SHP_GOODSMOVEMENT. To implement a BAdI, use transaction code SE19 or follow menu path SAP menu > Tools > ABAP Workbench > Utilities > Business Add-Ins > SE19 – Implementation (Figure 13). Enter the BAdI in the Enhancement Spot field and click on the Create Impl. button. This leads you to the screen shown in Figure 14. Enter a name (e.g., ZTEST) in the Enhancement Implementation field and a short description for your implementation in the Short Text field. Then, click on the green check icon circled in the figure. For more details, you should consult your ABAP developer.

Figure 13
Implement a BAdI

Figure 14
Provide a name and short description for the BAdI implementation
Intervening at this stage does not affect EDI and you don’t need to change any configuration. The one disadvantage is that SAP Note 1133399 cannot handle this case if you’ve charged the cost to the Amsterdam company.
4. FI Document for Goods Issue
Go to the CO substitution by following menu path SPRO > Controlling > General Controlling > Account Assignment Logic > Define Substitution (Figure 15). In the CO substitution, you can define the logic to determine under what situation you can remove the cost center. Double-click on the substitution circled in Figure 15 for this scenario and you find typical criteria for the substitution logic, as shown in Figure 16.

Figure 15
Substitution to remove the cost center for a cross-company free- of-charge sales order

Figure 16
Substitution logic to remove the cost center
Note
Normally, you do not use a cost center in a cost of sales account because a cost of sales account’s cost object should be a profitability segment. Therefore, removing the cost center for a cost of sales account via substitution has minimal risk of causing data problems and inconsistency. However, if you have a special situation in which you really need to post a cost center to a cost of sales account, you need to refine the definition of the substitution logic that I’ve provided.
In this logic, the system first checks if the reference procedure COBL-VORGN is RMWL, which means the FI document is triggered from an MM goods issue. Then the system checks if this FI document is coming from a cross-company sales order, which means that the FI document is posting to the inter- company cost of sales account. Finally, the system checks if this cross-company sales order is free of charge, which means that the cost center has value because only a free-of-charge sales order passes a cost center value to the FI document.
This scenario also has no impact on EDI and you don’t need any ABAP resources because all changes are within the CO substitution. If your system has already implemented a lot of CO substitution, however, this causes an extra burden and bottleneck to the system.
Recommendation
Except for the first method of removing the cost center at the sales order header, all other three solutions can effectively solve the problem. If you aren’t charging material cost to the Amsterdam delivery plant’s cost center, simply implementing SAP Note 1133399 is the most straightforward and effective method. Otherwise, I recommend removing the cost center at the delivery order by changing the copy routine.
The reason I recommend changing the copy routine is because normally you need different pricing for a free-of-charge sales order and thus you must have configured a separate sales order type for that. Because copy control is a sales order-type specific configuration, you can make the changes specific and restricted to the effected sales order type only. On the contrary, using a BAdI or CO substitution inevitably affects every business process and you have to define the logic in the BAdI program or substitution with extra care. Consequently, the regression testing effort and the cost of implementation are higher.
Lawrence Chung
Lawrence Chung has been working in SAP FI/CO since 1999 and was a consultant with SAP Hong Kong in 2001. He’s a CPA in Hong Kong and a fellow member of the Association of Chartered Certified Accountants. He has been acting as the lead FI/CO consultant in SAP implementations for many leading multinational corporations in various industries. He specializes in Controlling (CO-PA, CO-PC, and ML) and FI/CO integration with logistics (SD/MM, Service Management, and Project System).
You may contact the author at lawrencechung@hotmail.com.
If you have comments about this article or publication, or would like to submit an article idea, please contact the editor.