‎2006 Apr 06 2:11 PM
Hello!
What does funcion module (FM) transaction_begin do?
What does funcion module (FM) transaction_end do?
How can I use these FM?
With these once can I create a LUW, with bapi commit or rollback also?
Thank for your attention.
‎2006 Apr 06 2:30 PM
Hello Maria,
You can get the transaction number of your LUW.
Sequence of use is like
TRANSACTION_BEGIN
do processing of BAPI...
if something wrong
TRANSACTION_abrot
else.
TRANSACTION_END
Regards,
Naimesh.
‎2006 Apr 06 4:10 PM
Hello!
if I execute these step:
TRANSACTION_BEGIN
do processing of BAPI(1)...
do processing commit bapi(1)
do processing of BAPI(2) connected to BAPI(1)
if something wrong
TRANSACTION_abrot
else.
TRANSACTION_END
does the transaction_abort execute the rollack of bapi(1) and bapi(2)?
P.S. the commit between bapi(1) and bapi(2) is mandatory.
thanks
‎2007 May 01 3:23 PM
Hi Maria,
In the example that you have detailed, it is my understanding that TRANSACTION_ABORT will only rollback to the latest commit within the LUW. If no commit then the whole transaction is rolled back.
I am pretty sure that TRANSACTION_ABOUT would only rollback bapi(2) and the processing of bapi(1) would remain.
Thanks
Gary
‎2006 Apr 06 2:40 PM
Hello Maria,
This is another way of doing a commit. for e.g..
CALL FUNCTION 'TRANSACTION_BEGIN'
CALL FUNCTION 'BAPI_GOODSMVT_CREATE'
CALL FUNCTION 'BAPI_OBJCL_DELETE'
CALL FUNCTION 'BAPI_OBJCL_CREATE'
if sucess
CALL FUNCTION 'BAPI_TRANSACTION_COMMIT'
else
CALL FUNCTION 'BAPI_TRANSACTION_ROLLBACK'
endif
CALL FUNCTION 'TRANSACTION_END'