Symptom
When calling API JOURNALENTRYCREATEREQUESTCONFI , an error message is returned: "The withholding tax base amount exceeds the customer detail or vendor detail *."
Environment
SAP S/4HANA Cloud Public Edition
Cause
The ReferenceDocumentItem field in the WithholdingTaxItem node identifies the item linked to its corresponding creditor or debtor.
For all other items, such as Debitor Item, Credit Item, Items, and Product Tax Item, the system disregards the value provided in the 'ReferenceDocumentItem' field and instead, automatically assigns Accounting Document Line Item Number based on the predefined order listed:
- Debitor Item
- Credit Item
- Items
- Product Tax Item
Resolution
See examples:
In scenarios where a single DebitItem is present and the intention is to assign the WithholdingTaxItem to the CreditItem, the 'ReferenceDocumentItem' in the payload should be set to 2
| ReferenceDocumentItem in payload | Accounting Document Line Item Number | |
| Item | 1 | 3 |
| DebitorItem | 2 | 1 |
| CreditItem | 3 | 2 |
| WithholdingTaxItem | 2 | |
| ProductTaxItem | 4 | 4 |
| ProductTaxItem | 5 | 5 |
In scenarios where two DebitItem are present and the intention is to assign the WithholdingTaxItem to the CreditItem, the 'ReferenceDocumentItem' in the payload should be set to 3
| ReferenceDocumentItem in payload | Accounting Document Line Item Number | |
| Item | 1 | 4 |
| DebitorItem | 2 | 1 |
| DebitorItem | 3 | 2 |
| CreditItem | 4 | 3 |
| WithholdingTaxItem | 3 | |
| ProductTaxItem | 5 | 5 |
| ProductTaxItem | 6 | 6 |
See Also
- Refer to: 3486067 - How to post multiple debtor or creditor line items in API Journal Entry Post - SAP S/4HANA Cloud Public Edition
- Refer to: 2870954 - API Journal Entry - Post with withholding tax
- Refer to: Posting Supplier Invoices with Withholding Tax | SAP Help Portal
- Refer to: Error Handling | SAP Help Portal
Keywords
S4HC API, JOURNALENTRYCREATEREQUESTCONFI, withholding tax base amount, error message 003, ReferenceDocumentItem, debtor records, creditor records, XML payload, API structure, withholding tax item, N:N condition , KBA , AC-INT-2CL , Accounting Interface (Public Cloud) , Problem
SAP Knowledge Base Article - Public