‎2009 Aug 13 4:52 PM
Hi All,
I am trying to create Journal entries using the BAPI BAPI_ACC_DOCUMENT_POST.
After executing the BAPI the following error message occurs:
" Accounting transaction category RFBU 000000000000 is not defined "
(Message class: AAPO Message 161 )
During the execution of the BAPI the function module TABWD_READ
tries to select data from the table TABWD using the key
TCODE = RFBU 000000000000.
But no entry is available in the table.
In transaction F-02 we manually make the postings and everything works fine.
My test data is:
OBJ_TYPE = empty
OBJ_KEY = empty
OBJ_SYS = empty
BUS_ACT = RFBU
COMP_CODE = 1000
DOC_DATE = 12.05.2009
PSTNG_DATE = 12.05.2009
DOC_TYPE = SA
Please let me know if I am missing some parameters or how should I make an entry in TABWD entry or should I use a different BAPI for Journal entry postings?
I have seen couple of other similar SDN postings but could not find a solution.
Thanks in Advance!
Sonali.
‎2009 Aug 13 5:18 PM
Hello, the error presenting refers to the module AM, its posting of this module?. In the TABWD table there are entries for assets (AM) transactions.
Edited by: JOSE ALBEIRO HUERTAS MARTINEZ on Aug 13, 2009 11:21 AM
‎2009 Aug 14 9:48 PM
‎2009 Aug 15 10:32 AM
Hi ,
When you manually posted the document using f-02 find the transaction type IN BKPF Table and field GLVOR .
The code below is working fine.
bapiache09-username = 'ABAPUSER1'.
bapiache09-bus_act = 'RFBU'.
bapiache09-comp_code = 'RS01'.
bapiache09-pstng_date = '20090230'.
bapiache09-doc_date = '20090230'.
bapiache09-doc_type = 'KY'.
it_bapiacgl09-itemno_acc = '0000000001'.
it_bapiacgl09-gl_account = '0024520080'.
it_bapiacgl09-comp_code = 'RS01'.
it_bapiacgl09-bus_area = 'BARD'.
*it_bapiacgl09-doc_type = 'KY'.
*it_bapiacgl09-acct_type = 'K'.
APPEND it_bapiacgl09 .
clear it_bapiacgl09.
it_bapiacap09-itemno_acc = '0000000002'.
it_bapiacap09-vendor_no = 'MSHS0100'.
*it_bapiacap09-gl_account = '0013000001'.
*it_bapiacap09-comp_code = 'RS01'.
*it_bapiacap09-bus_area = 'BARD'.
*it_bapiacap09-doc_type = 'KY'.
*it_bapiacap09-acct_type = 'K'.
*it_bapiacap09-PYMT_AMT = '1287'.
*it_bapiacap09-PYMT_CUR_ISO = 'INR'.
APPEND it_bapiacap09.
clear it_bapiacap09.
it_bapiaccr09-itemno_acc = '0000000001'.
it_bapiaccr09-currency_iso = 'INR'.
it_bapiaccr09-amt_doccur = '-1287'.
it_bapiaccr09-amt_base = '-1287'.
APPEND it_bapiaccr09.
clear it_bapiaccr09.
it_bapiaccr09-itemno_acc = '0000000002'.
it_bapiaccr09-currency_iso = 'INR'.
it_bapiaccr09-amt_doccur = '1287'.
it_bapiaccr09-amt_base = '1287'.
APPEND it_bapiaccr09.
clear it_bapiaccr09.
CALL FUNCTION 'BAPI_ACC_DOCUMENT_POST'
EXPORTING
documentheader = bapiache09
* CUSTOMERCPD =
* CONTRACTHEADER =
* IMPORTING
* OBJ_TYPE =
* OBJ_KEY =
* OBJ_SYS =
TABLES
accountgl = it_bapiacgl09[]
* ACCOUNTRECEIVABLE =
accountpayable = it_bapiacap09[]
* ACCOUNTTAX =
currencyamount = it_bapiaccr09[]
* CRITERIA =
* VALUEFIELD =
* EXTENSION1 =
return = it_return[]
* PAYMENTCARD =
* CONTRACTITEM =
* EXTENSION2 =
* REALESTATE =
* ACCOUNTWT =
.
*
*
*CALL FUNCTION 'BAPI_TRANSACTION_COMMIT'
** EXPORTING
** WAIT = 5
*** IMPORTING
** RETURN =
* .Regards
Nilesh
‎2009 Aug 24 9:49 PM
Hi All,
Thanks for your feedback.
I need to combine Asset accounts & G/L accounts into a single GL document posting. I need to pass the transaction type 'RFBU' as it is a manadatory field. But if I pass the value it gives the error :
"Accounting transaction category RFBU 000000000000 is not defined"
Should there be an entry in TABWD table via config? or is there any othe BAPI that solves my problem?
When I post manually through F-02 everything works fine and the document type is 'SA'. Only with posting key '70' i.e. Asset account it gives the error.
Thanks in advance!
Sonali.