Skip to Content
0

Block vendor invoice with BAPI_ACC_PYMNTBLK_UPDATE_POST

Apr 05 at 04:11 PM

87

avatar image

Hello to everyone,

Here is the situation: We have created several vendor invoices with the transaction code FB60, all the vendor invoices can be seen at the transaction code FBL1N. The problem is, we would like to block some open vendor invoices with BAPI, we had used BAPI_ACC_PYMNTBLK_UPDATE_POST to do so, we also used the commit transaction. The return of the BAPI was a successful message (something like 'Document posted successfully'), but when we go to the FBL1N transaction the item isn't blocked. Other weird thing, is that in the BAPI_ACC_PYMNTBLK_UPDATE_POST we can't pass the reason of the payment block, this is confusing, because at the GUI we have to set the reason of the block. The question is, Is there anything else we have to do to make this bapi work? We do not see the block flag set on the invoice in table BSEG.

10 |10000 characters needed characters left characters exceeded
* Please Login or Register to Answer, Follow or Comment.

1 Answer

Raymond Giuseppi
Apr 06 at 07:50 AM
1
  • Did the BAPI return any Warning/Error message in RETURN parameter?
  • Does the BAPI trigger FI_PAYMENT_BLOCK_UPDATE in your system (is the FM associated to the process 'PYMNTBLK' in table TRWPR)

Hint: Try to put a break-point at start of FI_PAYMENT_BLOCK_UPDATE.

Show 3 Share
10 |10000 characters needed characters left characters exceeded

  • Did the BAPI return any Warning/Error message in RETURN parameter?

No, saddly there is no error. The BAPI return looks as follow:

"TYPE": "S",
"ID": "RW",
"NUMBER": "605",
"MESSAGE": "Document posted successfully: BKPF 000000120412352018",
"LOG_NO": "",
"LOG_MSG_NO": "000000",
"MESSAGE_V1": "BKPF",
"MESSAGE_V2": "000000120412352018",
"MESSAGE_V3": "",
"MESSAGE_V4": "",
"PARAMETER": "",
"ROW": 0,
"FIELD": "",
"SYSTEM": "ECW_00_800"

  • Does the BAPI trigger FI_PAYMENT_BLOCK_UPDATE in your system (is the FM associated to the process 'PYMNTBLK' in table TRWPR)

No, the BAPI does not make any calls to the FI_PAYMENT_BLOCK_UPDATE. I have tried to run it with the debug and i haven't seen anything that looks like this FI.

0

Did you look at table TRWPR for Business Transaction PYMNTBLK?

* Content sample
* BusTran., Time, Sequence number, Component For docmt, Function Module
* PYMNTBLK, CHECK, 10, FI,  FI_PAYMENT_BLOCK_CHECK
* PYMNTBLK, UPDATE, 10, FI,  FI_PAYMENT_BLOCK_UPDATE
* PYMNTBLK, UPDATE, 11, EAFM,  FM_PAYMENT_BLOCK_UPDATE


0

Hi Raymond, Thanks for the reply

We solve the problem by developing an ABAP program that calls FI_DOCUMENT_CHANGE inside of it. Then, we don't need to use FI_PAYMENT_BLOCK_UPDATE anymore. But, thanks for the help.

0