MESSAGE_TYPE_X in SAP ABAP
We are getting a Short dump MESSAGE_TYPE_X in the ABAP Program "SAPLPS_BAPI" - in "CHK_PRECOMMIT". The main program was "SAPMHTTP".
To resolve this dump please do as follow:
BAPI_TRANSACTION_COMMIT is called although the BAPI_PS_PRECOMMIT delivers an error and therefore is not executed.
Your source code is supposed to check here whether BAPI_PS_PRECOMMIT supplied an error and handle it correspondingly.
A database commit is executed somewhere in your own source code.
The usage of the BAPI_PS_INITIALIZATION is not at the right position.
Please take into account: the correct order is always BAPI_PS_INITIALIZATION -> BAPI_NETWORK_CHANGE -> BAPI_PS_PRECOMMIT -> BAPI_TRANSACTION_COMMIT.
Also, it could happen if you use the commit work without a precommit.
If you called the precommit before, please check in BAPI_PS_PRECOMMIT the flag is set in line 170:
* No error whilst GUID retrieval or we just deal with a status change
call function 'PS_FLAG_SET_GLOBAL_FLAGS'
i_precommit_ok = 'Y'.
This piece of coding should be called directly before the commit work.