Hi all, I am using BAPI_ALM_ORDER_MAINTAIN within a workflow to release a PM order which is created by the workflow in a step before with ALM_ME_ORDER_CREATE, followed by ALM_ME_ORD_BAPI_ORDER_POST and BAPI_TRANSACTION_COMMIT. That works fine and the result is a PM order that is not yet released. After the BAPI_TRANSACTION_COMMIT I have tried SET UPDATE TASK LOCAL, as well as WAIT UP TO 180 SECONDS. I also stopped the workflow to control whether all data is written to the database and I found all data of the PM order properly. BUT BAPI_ALM_ORDER_MAINTAIN always issued an error message saying that the data for the procedure (Vorgang) are not maintained for the PM order. If I run the BAPI_ALM_ORDER_MAINTAIN alone it works, same with the function I created as well as the method of the business object as well as the task for the workflow. As soon as the workflow runs it - error message, no release. Even if you release the PM order manually with IW32 the PM order is fine and released. No error message at all. My conclusion is that WF_BATCH cannot run the BAPI caused by lag of user rights also it has SAP_ALL. This makes no sence but might be the solution of the problem. Does anybody have an idea what's wrong?
↧