Skip to Content
0

BAPI_TRANSACTION_COMMIT along with CALL FUNCTION BAPI_PO_CHANGE DESTINATION 'NONE'

Feb 16, 2017 at 10:20 AM

379

avatar image

Hi All,

I need a little clarification on the use of BAPI_TRANSACTION_COMMIT.

We have a custom program which updates lot of POs sequentially using BAPI_PO_CHANGE and then calls BAPI_TRANSACTION_COMMIT(for each call)

After the support pack upgrade recently, we are getting a erratic dump 'OBJECTS_OBJREF_NOT_ASSIGNED' from this custom program

We checked the Note 2406654 - Strange behavior when calling different BAPIs in a
custom program, the note recommends to use DESTINATION 'NONE' clause along with MM BAPIs to prevent the dump.

I understand DESTINATION 'NONE' will invoke a implicit commit, and so, is it safe to call BAPI_TRANSACTION_COMMIT after the BAPI_PO_CHANGE DESTINATION 'NONE' ?

Regards,

Arunkumar C N

10 |10000 characters needed characters left characters exceeded
* Please Login or Register to Answer, Follow or Comment.

3 Answers

Best Answer
Raymond Giuseppi
Feb 16, 2017 at 10:33 AM
1

If only standard SAP BAPI are called, yes it's safe. Usually such implicit commit can only mess with data in customer program which executed some open-sql statements.

Share
10 |10000 characters needed characters left characters exceeded
Chintu adi Feb 16, 2017 at 10:45 AM
-1

Hello,

yes its safe to use BAPI_TRANSACTION_COMMIT

as DESTINATION 'NONE'.

it pushes the execution of a RFC/ BAPI in a new separate session and need to explicitly close that session so that all relevant database commits are actually triggered before continuing.

BAPI_TRANSACTION_COMMIT is called to COMMIT a database operation as commit has to take place in remote work process.

As we can not write COMMIT WORK statement after BAPI, we need to call BAPI_TRANSACTION_COMMIT is used to update the database after all the transactions in a LUW are completed successfully.

for more details refer the following link

https://wiki.scn.sap.com/wiki/display/ABAP/BAPI_TRANSACTION_COMMIT+versus+COMMIT+WORK

thank you!!

Show 2 Share
10 |10000 characters needed characters left characters exceeded

As we can not write COMMIT WORK statement after BAPI, we need to call BAPI_TRANSACTION_COMMIT is used to update the database after all the transactions in a LUW are completed successfully.

We cannot or we should not? There's a difference ...

1

should not

0
omer sakar Feb 16, 2017 at 02:37 PM
0

Hi,

While Calling RFC with DESTINATION 'NONE',consider attached part of document on link : https://www.virtualforge.com/tl_files/web/Theme/Presentations/BIZEC14_SAP_Security_beyond_authorizations.pdf


Share
10 |10000 characters needed characters left characters exceeded