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

Problem With BDC

Former Member
0 Likes
567

Hi,

I am testing a scenario with Goods Movement. In case of goods receipt, I am supposed to post the characteristics data for a specified batch of a specified material. I am creating the batch with FM <b>BAPI_GOODSMVT_CREATE</b> and then using a CALL TRANSACTION to populate the values of characteristics through tcode <b>MSC2</b>. The entire work is done wihin an RFC wrapper. The problem is, whenever I run the RFC from se37, I get desired result; but when I call the RFC from my other system, batch is created, but <b>the characteristics values do not get populated.</b> I have checked that the GOODSMVT BAPI works fine (BAPIRETURN structure is clear) and BDC issues an error message <b>"Batch <Batch-Number> is already locked by user <Username>".</b> First I thought it was a concurrency control issue, but running the BDC in forground it appeared that <b>when the first screen for characteristics is populated and the OK_CODE for <i>BACK</i> is used, the BDC issues the above mentioned message there and exits; without passing through the OK_CODE for 'SAVE'</b>. can any one point out why the BDC is acting so abnormally? Or have I made any mistake? And is there any workaround for the above problem?

Awaiting your reply sincerely. points will be rewarded to any helpful answers.

Regards,

Amitabha

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
517

Hi Amitabha

Maybe you can try by delaying the process of processing the BDC by using WAIT statement.

Also, if you find having problem with BDC you might consider using FM's of function group: <b>VBWB</b>.

Kind Regards

Eswar

3 REPLIES 3
Read only

Former Member
0 Likes
518

Hi Amitabha

Maybe you can try by delaying the process of processing the BDC by using WAIT statement.

Also, if you find having problem with BDC you might consider using FM's of function group: <b>VBWB</b>.

Kind Regards

Eswar

Read only

Former Member
0 Likes
517

Hi,

After the bapi call..Give COMMIT WORK AND WAIT..THis will make sure all the V1 updates are complete..Then call the BDC..

Thanks,

Naren

Read only

0 Likes
517

Dear Eswar and Narendran,

Both of you pinpointed at the same problem..and both hit bulls eye! My problem is solved..many thanks to you two! I have awarded points to both of you..Would have loved to award maximum to both of you..but SDN doesn't allow joint winners, I guess..so had to resolve it in FIFO manner...hope you don't mind! Kudos to you two geniuses!

Regards,

Amitabha