‎2010 Oct 19 4:31 AM
I have 2 bapis:
I have called 2 bapis.
I have to commit the first bapi , only second bapi also succesful.Please look below code i have used is it correct?
i did like below:
call first BAPI
check return table for type 'E'.
if no type E messages:
call 2nd BAPI.
if this return table also dont have type E messages.
then BAPI_TRANSACTION_COMMIT.
will this transaction updates 2 bapis data ?
if not how can i handle this?
‎2010 Oct 19 4:46 AM
‎2010 Oct 19 5:02 AM
‎2010 Oct 19 5:24 AM
‎2010 Oct 19 6:26 AM
Hi
call 1st BAPI.
read return table with type 'E'.
if sy-subrc <> 0.
call 2nd BAPI.
read return table with type 'E'.
call BAPI_TRANSACTION_COMMIT.
endif.
Hi the above flow is correct, because the commit BAPi will commit all the BAPIs used above it in the program.
Thanks
Lalit Gupta
‎2010 Oct 19 6:55 AM
Hi Ramakrishna,
This BAPI is used to update the database after all the transactions in a LUW are completed successfully. After execution of this BAPI all the related tables are updated in the database. Any operation which requires the database tables updation, this BAPI can be used
So have a check for SY-SUBRC to ensure there is a correct updation happening.
Check for the OSS notes if you want any further information.
https://service.sap.com/sap/support/notes/798535
Thanks and Regards.
Srikanth.P
‎2010 Oct 19 7:07 AM
HI,
you're fine, I would check also if any Abort messages are thrown...
Regards,
Ivan