04-16-2017 7:03 AM
Hi guys,
I've created a 'Z' function module to call it 'IN UPDATE TASK' inside an EXIT (EXIT_SAPLLMDE_006). This EXIT is right after a MB_CREATE_GOODS_MOVEMENT, that performed a 101 moviment.
In my function, I'm performing another MB_CREATE_GOODS_MOVEMENT but to moviment 311. When system reach my 'Z' function, the moviment before (101) is not commit yet, than my moviment stops because there is an ENQUEUE of purchase table, but the table is being used in moviment 101 (means to me that my function is not being called in update task).
My 'Z' function is 'Update Module' and 'Star Immed.'.
Thanks!!
04-16-2017 7:21 AM
As you probably understood, you can't make it work as you planned, you have to find another workaround. One way is to schedule a subsequent job to do this additional movement, for instance using workflow or tRFC (CALL FUNCTION IN BACKGROUND TASK). You'll have to handle exceptions (lock for instance) asynchronously (mail by workflow for instance, or SM58).
04-16-2017 7:21 AM
As you probably understood, you can't make it work as you planned, you have to find another workaround. One way is to schedule a subsequent job to do this additional movement, for instance using workflow or tRFC (CALL FUNCTION IN BACKGROUND TASK). You'll have to handle exceptions (lock for instance) asynchronously (mail by workflow for instance, or SM58).
04-18-2017 6:48 PM
Hello mrs. Rossi.
Worked as you said. I've changed my function to 'Remote-Enabled Module' and called it 'IN BACKGROUND TASK AS SEPARATE UNIT' and worked. The process before my function finished and in SM58 I was able to check my function working fine. I also put a 'infinite loop' and could see the function running.
I appreciate your help.
04-16-2017 2:50 PM
Hi,
You can try with
My 'Z' function is 'Update Module' and 'Star Delayed.' Otherwise Put wait up to 2 seconds in the FM.
04-18-2017 6:52 PM