on 09-12-2017 8:30 AM
Hi All,
After posting is done using contract number a document number is created, for that contract number we are raising invoice using RERAIV t-code.
While creating invoice for a contract number an invoice number is generated, that invoice number should be updated in XREF1_HD field in BKPF table.
I have tried using bapi_acc_document_post but bkpf table is not getting updated .Is there anyother BAPI which is used to update BKPF table?
If someone have resolved this issue please let me know.
Thanking you.
Mallikarjunan K
Hi dear,
You should use below Function module after calling bapi_acc_document_post
if sy-subrc eq 0 .
call function 'BAPI_TRANSACTION_COMMIT'
exporting
wait = 'X'.
endif.
Then only It will update BKPF table.
or else You need to customize your own Function module from bapi_acc_document_post.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi,
You need to pass some data in document header . Create one work area for document header like this.
data: gs_head type BAPIACHE09.
Then pass required data in it.
gs_head-username = sy-uname.
gs_head-comp_code = <companycode>.
gs_head-doc_type = 'SA'. "Document Type
gs_head-ref_doc_no = <reference text. "Reference No
gs_head-fisc_year = <fiscal year>.
gs_head-doc_date = <date>
gs_head-pstng_date = <date>.
After that pass gs_head to document header.
Then Bapi will work.
User | Count |
---|---|
15 | |
4 | |
2 | |
1 | |
1 | |
1 | |
1 | |
1 | |
1 | |
1 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.