Application Development Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 

Best way to solve the issue already being processed by User.

former_member196331
Active Contributor
0 Kudos

I have small issue.

I am confirming the Production order Each operation using Bapi by using the below code.
Normally we can do it by using the tcode co11n. If suppose Production order contains
5 operations like 10 20 30 40 50,
First i need to confirm 10 operation, the conformation has to do, operation wise, otherwise system won't allow.

Below bapi is calling . Operation wise.

First i am calling bapi for operation 10...Completed..

While doing 20th Operation..Now system is showing error like Order 100003381 is already being processed by User means (my user id).So next operations all are failing because 20th operation has not done.

Some time everything is ok, Some times error is coming.Any solution for this.

CALL FUNCTION 'BAPI_PRODORDCONF_CREATE_TT'

EXPORTING
post_wrong_entries = '1'
testrun = ''
IMPORTING
return = return
TABLES
timetickets = bapi_pp_timeticket[]
* GOODSMOVEMENTS =
* LINK_CONF_GOODSMOV =
* CHARACTERISTICS_WIPBATCH =
* LINK_CONF_CHAR_WIPBATCH =
* DETAIL_RETURN =
* CHARACTERISTICS_BATCH =
* LINK_GM_CHAR_BATCH =
.
IF sy-subrc EQ 0.
COMMIT WORK.
ENDIF.

1 ACCEPTED SOLUTION

pokrakam
Active Contributor

It means the previous update hasn't completed and is still active in background. Use COMMIT WORK AND WAIT.

Or better still, use BAPI_TRANSACTION_COMMIT with WAIT = abap_true

6 REPLIES 6

pokrakam
Active Contributor

It means the previous update hasn't completed and is still active in background. Use COMMIT WORK AND WAIT.

Or better still, use BAPI_TRANSACTION_COMMIT with WAIT = abap_true

0 Kudos

I will check it.

0 Kudos

Hope working. checked with two production orders. Working like a jet speed. Thank you.

0 Kudos

Hi mike.pokraka Thanks for the input , but not working for us . Kindly provide any alternate solution if available

0 Kudos

nvkprasad As you can see, Mike answer has solved the OP question, so you are in another context and you should post a new question and explain what you have analyzed, tried, etc.

0 Kudos

If using the 'COMMIT WORK', how long or where can we check to see what the average commit work time is to verify? When you say sometimes it works and sometimes it does not, how do you go about checking the commit times?