‎2008 Jan 25 4:58 PM
How to use Call Transaction / Bapi plus Commit work in a Update task.
We have configured a output type for Purchase order, so when ever a PO is created via Me21N a sales order needs to be created. I tried using Bapi BAPI_SALESORDER_CREATEFROMDAT1 in the routine but
BAPI_TRANSACTION_COMMIT is not working as this is all happening in Update task.
How to create a SO in the above case?
Thanks in advance
Cheers!!
Anand
‎2008 Jan 28 2:08 PM
Hi Anand,
I understand that your requirement is to create a sales order on creation of purchase order.
I guess you can do the same in the BADI ME_PURCHDOC_POSTED.
Please try implementing the same. This BADI will be triggered whenever the purchase document is posted.
Please go ahead and implement your sales order logic in this BADI and let me know if this solution works for you.
Regards,
Hariharan
‎2008 Jan 28 2:13 PM
Anand,
I would try calling out to a new program using SUBMIT Z_YOUR_NEW_PROGRAM.
And have the new Z program create the SO as needed.