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

BAPI_REQUISITION_CREATE

Former Member
0 Likes
827

Hello all,

I'm a newbie to ABAP and SAP so I might not express my problem clearly. I'm trying to use BAPI_REQUISITION_CREATE to create 3 different PRs based on some specifications in my BADI when a material document is posted. I'm calling the BAPI 3 times and it works fine when used directly in SAP- that is when I post a material document using MB1B for example, it works fine and creates different PRs.

When I test with batch, on the first call of BAPI_REQUISITION_CREATE, only the first PR is created and it doesn't return to the program to create the other types of PRs if any. This is a problem because I need for it to function with both batch and directly.

Any suggestions? I know the commit statement in this BAPI is responsible and I have tried using BAPI_PR_CREATE but I'm running into more problems.

Any help will be greatly appreciated. Thanks

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
562

For anyone that needs the information, I just copied the standard BAPI to a ZBAPI and commented out the commit statement in the BAPI. It works fine with both batch and direct material document posting.

1 REPLY 1
Read only

Former Member
0 Likes
563

For anyone that needs the information, I just copied the standard BAPI to a ZBAPI and commented out the commit statement in the BAPI. It works fine with both batch and direct material document posting.