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

How does BAPI_PO_CREATE1 and BAPI_TRANSACTION_COMMIT works?

Former Member
0 Likes
468

Hi Folks,

I have a little question about BAPI_TRANSACTION_COMMIT mainly.

I was wondering if I call 2 times BAPI_PO_CREATE1 before calling BAPI_TRANSACTION_COMMIT will this create 2 POs or this will create only the last PO in memory?

Another thing is that if the 2 POs are created in memory, the 2nd PO validation checks take in count the 1st PO, for example, total item quantity(1st PO + 2nd PO) don't exceed the purchase requisition item quantity.

Thanks in advance for your help.

Regards,

Gilberto Li

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
430

Hello Gilberto,

BAPI_TRANSACTION_COMMIT is the signal to write the data to the database. So, if you have two PO's created via BAPI_PO_CREATE1, at the point of the commit they are both stored to database.

If the two PO's are not independent form each other, you should commit after the first. Else the second can't check, that the first is existing.

Regards Wolfgang

2 REPLIES 2
Read only

Former Member
0 Likes
431

Hello Gilberto,

BAPI_TRANSACTION_COMMIT is the signal to write the data to the database. So, if you have two PO's created via BAPI_PO_CREATE1, at the point of the commit they are both stored to database.

If the two PO's are not independent form each other, you should commit after the first. Else the second can't check, that the first is existing.

Regards Wolfgang

Read only

0 Likes
430

Thanks Wolfgang for your help.