2008 Jun 25 10:15 AM
Hi All,
I am trying to reverse the accounting document using BAPI "BAPI_ACC_DOCUMENT_REV_POST"
and finally using"BAPI_TRANSACTION_COMMIT " .
can any one provide me sample data to be passed to the two paramters:
REVERSAL
BUS_ACT
Please help me in reversing the accounting document number..
Any Suggestions of other BAPI to reverse the accounting document are also would be of great help to me..
Thanks in advance.
Prathima..
Hi All,
I am trying to reverse the accounting document using BAPI "BAPI_ACC_DOCUMENT_REV_POST"
and finally using"BAPI_TRANSACTION_COMMIT " .
can any one provide me sample data to be passed to the two paramters:
REVERSAL
BUS_ACT
Please help me in reversing the accounting document number..
Any Suggestions of other BAPI to reverse the accounting document are also would be of great help to me..
Thanks in advance.
Prathima..
2008 Jun 25 11:01 AM
2008 Jun 25 11:04 AM
Hi wong,
Thanks for the reply..
Can you please post some sample data to fill up the parameters please..
thank you..
2008 Jun 25 11:09 AM
Hi,
Check this code below.
data: rev like BAPIACREV,
bus like bAPIACHE09-BUS_ACT,
ret like table of bapiret2 with header line.
data: flg(1) type c.
rev-obj_type = 'BKPFF'.
rev-obj_key = 'docnocompcodeyear'.
REV-OBJ_KEY_R = 'docnocompcodeyear'.
rev-PSTNG_DATE = '20070611'.
rev-FIS_PERIOD = '06'.
rev-COMP_CODE = 'comp_code'.
REV-REASON_REV = '02'.
REV-obj_sys = sy-mandt.
CALL FUNCTION 'BAPI_ACC_DOCUMENT_REV_POST'
EXPORTING
REVERSAL = rev
BUS_ACT = 'RFBU'
IMPORTING
OBJ_TYPE =
OBJ_KEY =
OBJ_SYS =
TABLES
RETURN = ret.
Thanks
Nayan
2008 Jun 26 8:17 AM
Hi nayan,
I tried the same code u have mentioned...
the return mesage from BAPI is successful with the message
"Document posted successfully: BKPFF 1600000269DC102008 I00CLT030"
I committed the BAPI also... but still I couldnt find the reversed accounting doc number for this in the BKPF table.
I was getting an express document "Update was terminated" after the execution of the prog.
Please help me on this issue...
regards,
Prathima.
2008 Oct 12 11:00 PM
I am getting the exact same update termination message. You can see the details using transaction SM13. It appears that the system proposes a new document number to reverse the original document, and then errors out with the message "line 001 of the original document has already been cleared" which is not in fact the case.
To further muddy the waters the update termination does not always occur.
| User | Count |
|---|---|
| 3 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 |