Skip to Content
0
Jul 30, 2020 at 11:42 AM

BAPI_ACC_DOCUMENT_POST - Incorrect Base Amount in FB03

172 Views

I am using BAPI_ACC_DOCUMENT_POST for mass create AP invoice. But I found that the base amount and tax amount of created invoice are wrong. It will sum up all the base amount, it will ignore whether it is debit or credit entry (+/-) in currencyamount table.

Anyone can help? I can't find the exact solution from the internet. Below is my value in Bapi, Only two items total. But it only shows either a credit base amount or debit base amount in fb03's tax data. Any missing field?

ACCOUNTGL-ITEMNO_ACC = 2 / 5 //SAME VALUE

ACCOUNTGL-GL_ACCOUNT = 75140060

ACCOUNTGL-ITEMTEXT = TESTING

ACCOUNTGL-COMP-CODE = 12

ACCOUNTGL--VALUE_DATE = 2020204

ACCOUNTGL-TAX_CODE = V1

ACCOUNTPAYABLE-ITEMNO_ACC = 1 /4 /SAME VALUE

ACCOUNTPAYABLE-VENDOR_NO = VEND123

ACCOUNTPAYABLE-COMP_CODE = 12

ACCOUNTPAYABLE-BLINE_DATE - 20200617

ACCOUNTPAYABLE-DSCT_DAYS1 = 3

ACCOUNTTAX - ITEMNO_ACC = 3 / 6 //same VALUE

ACCOUNTTAX -COND_KEY = MWVS

ACCOUNTTAX -ACCT_KEY = ZVP

ACCOUNTTAX -TAX_CODE = V1

ACCOUNTTAX -TAX_RATE = 19

CURRENCYAMOUNT- ITEMNO_ACC = 1

CURRENCYAMOUNT-CURRENCY = EUR

CURRENCYAMOUNT-AMTDOCCUR = 83.09-

CURRENCYAMOUNT- AMTBASE = 0

CURRENCYAMOUNT- ITEMNO_ACC = 2

CURRENCYAMOUNT-CURRENCY = EUR

CURRENCYAMOUNT-AMTDOCCUR = 69.82

CURRENCYAMOUNT- AMTBASE = 0

CURRENCYAMOUNT- ITEMNO_ACC = 3

CURRENCYAMOUNT-CURRENCY = EUR

CURRENCYAMOUNT-AMTDOCCUR =CURRENCYAMOUNT- ITEMNO_ACC = 1

CURRENCYAMOUNT-CURRENCY = EUR

CURRENCYAMOUNT-AMTDOCCUR = 13.27

CURRENCYAMOUNT- AMTBASE = 69.82

CURRENCYAMOUNT- ITEMNO_ACC = 4

CURRENCYAMOUNT-CURRENCY = EUR

CURRENCYAMOUNT-AMTDOCCUR =CURRENCYAMOUNT- ITEMNO_ACC = 1

CURRENCYAMOUNT-CURRENCY = EUR

CURRENCYAMOUNT-AMTDOCCUR = 85.97

CURRENCYAMOUNT- AMTBASE = 0

CURRENCYAMOUNT- ITEMNO_ACC = 5

CURRENCYAMOUNT-CURRENCY = EUR

CURRENCYAMOUNT-AMTDOCCUR =CURRENCYAMOUNT- ITEMNO_ACC = 1

CURRENCYAMOUNT-CURRENCY = EUR

CURRENCYAMOUNT-AMTDOCCUR = 72.24-

CURRENCYAMOUNT- AMTBASE = 0

CURRENCYAMOUNT- ITEMNO_ACC = 6

CURRENCYAMOUNT-CURRENCY = EUR

CURRENCYAMOUNT-AMTDOCCUR =CURRENCYAMOUNT- ITEMNO_ACC = 1

CURRENCYAMOUNT-CURRENCY = EUR

CURRENCYAMOUNT-AMTDOCCUR = 13.73-

CURRENCYAMOUNT- AMTBASE = 72.24-