04-05-2013 1:37 AM
Hello everyone,
I can't access our system right now, but i will try to summarize my issue :
We are making a vendor document posting via bapi BAPI_ACC_DOCUMENT_POST.
In customizing (FTXP), we have a tax code 'AM', containing 2 percentages rates :
Input tax VST 10,5 120 100 MWVS
Non deduct.input tax NVV 10,5 140 100 MWVZ
We filled the tables for the bapi (accountgl, accountpayable, accounttax, currencyamount).
Particularly for this tax code, we filled the last line of currency amount with the base_amount (amt_base 800) and amount tax (amt_doccur 84).
We also filled a line in accountax (linked with the same itemno_acc) to specify the condition type of the tax -> MWVS with a tax_rate.
BAPI is well executed and a document is created and we see (FB03) the item lines and the tax line at the bottom, good
But when we take a look at BSET table, we have a first line with transaction type VSF (NWMS), but too another line with transaction type NVV (MWVZ) (seems logic because it is in the custom calc procedure), but with a base amount of 884 (base + tax values? ...), and a tax amount of 42 (half of first line tax !
I don't know how SAP added the line for the condition MWVZ, because we didn't filled a second line in the accounttax table for condition...
I tried to debug the BAPI, and found at a point the table XBSET, already filled with these value; but couldn't find where this was calculated/filled by SAP.
Does someone would be so kind to guide us in finding how and why SAP give these amounts please?
Thank you in advance and best regards,
04-05-2013 6:41 AM
1.
BAPI_ACC_DOCUMENT_POST internally do a call transaction to FB01. You debug your program and put a break point on statement CALL TRANSACTION. Now check the posting in foreground mode. ( Change value to A from N). There look at tax line posting. I think you will get some clue.
2.
Some times extra lines comes in BSET with zero tax amount if there any zero tax rate maintain in FTXP.
3. If you does not get any clue from the other two step, you can try to post the document manually from FB01 with the same data and see the BSET table.
Thanks
Subhankar
04-05-2013 9:58 AM
Hello,
Thank you for the answer.
1) But when looking for "CALL Transaction" in the BAPI, i found nothing.
2) The extra lines contains a tax_amount with a value <> 0.
3) Business has tested the sames lines in a manual entry with FB01, and the MWVZ extra line is created with good values (the same as the other tax line MWVS).
Difference seems to be from the BAPI.
Regards,