2023 Oct 11 1:55 PM
Hello Folks,
Im trying to confirm production order using '' BAPI_PRODORDCONF_CREATE_TT '' but im getting random one order getting dump. I tried Lock mechanism and wait seconds upto 50 seconds to confirm one order confirmation.
below my codes are,
ALL FUNCTION 'ENQUEUE_ESORDER'
EXPORTING
aufnr = wa_bapi-aufnr
EXCEPTIONS
foreign_lock = 1
system_failure = 2
OTHERS = 3.
wa_timetckt-orderid = wa_bapi-aufnr.
CALL FUNCTION 'CONVERSION_EXIT_ALPHA_INPUT'
EXPORTING
input = wa_timetckt-orderid
IMPORTING
output = wa_timetckt-orderid.
wa_timetckt-operation = wa_bapi-vornr.
wa_timetckt-postg_date = sy-datum.
wa_timetckt-plant = wa_bapi-werks.
wa_timetckt-yield = wa_bapi-unconfirmed_quant.
APPEND wa_timetckt TO it_timetckt.
CALL FUNCTION 'BAPI_PRODORDCONF_CREATE_TT'
IMPORTING
return = return1
TABLES
timetickets = it_timetckt
detail_return = detail_return.
ALL FUNCTION 'DEQUEUE_ESORDER'
EXPORTING
aufnr = wa_bapi-aufnr.
WAIT UP TO 50 SECONDS.
Kindly give me a possible solution..
2023 Oct 11 1:56 PM
Hello Rajkumar,
Thank you for visiting SAP Community to get answers to your questions. Since you're asking a question here for the first time, I recommend that you familiarize yourself with https://community.sap.com/resources/questions-and-answers, as it provides tips for preparing questions that draw responses from our members.
Feel free to take our Q&A tutorial at https://developers.sap.com/tutorials/community-qa.html as well, as that will also help you when preparing questions for the community.
Should you wish, you can revise your question by selecting Actions, then Edit.
By adding a picture to your profile you encourage your readers to respond.
Kind regards,
Anne
2023 Oct 11 6:45 PM
Only you can investigate the deadlock. It may come from anywhere...
There is a SAP note which helps you locating the problem (to look into the developer trace)