Application Development and Automation 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: 
Read only

facing while using BAPI function module......

Former Member
0 Likes
332

Hi ,

In one of my program I am using Bapi function module

SD_SALESDOCUMENT_CHANGE to change the sales order.

after that I am using function module

CALL FUNCTION 'BAPI_TRANSACTION_COMMIT' with no parameterspassing to it.

After that I am releasing the same sales order using function module SD_ORDER_CREDIT_RELEASE.

this function module is giving error saying the Sales document xxxx is currently being processed by XXXXX user.

The above error is getting only some times when I start that particular program for the first time but not all the times.

I also put <b>commit work and wait</b> befor releasing that particular order.

How can i solve the issue.

Please let me know.

Thanks in advance

Raja

1 REPLY 1
Read only

uwe_schieferstein
Active Contributor
0 Likes
273

Hello Raja

I believe the error is indeed a timing problem with updating the DB table. However, Why don't you choose the following sequence?:

(1) Call SD_SALESDOCUMENT_CHANGE

(2) If successful, call SD_ORDER_CREDIT_RELEASE

(3) If successful, finally commit work.

Regards

Uwe