>I have a stateful session bean which has to execute four prepared
>statements, there is a dependency of a table between the first and the last
>statement. I also need to be able to rollback all the changes if exception
>occurs in any of the statements. Because of the dependency pages in the
>database gets locked, if I put them in separate transactions how do I
>rollback the changes.

If you put these in a seperate transaction, and since the EJB spec doesn't
support embedded transactions,
you'll have to manage the rollback yourself. Meaning you'll have to maintain
the previous state and somehow restore
it, should a rollback occur. This is very tricky and if you could perform
everything in the same transaction
I'd really urge you to do so.

Hope this helps,
Michael Moerman
THE CAPITAL MARKETS COMPANY
<mailto:[EMAIL PROTECTED]>
<http://www.capitalmarketscompany.com>
tel. + 32 495 58 88 46
fax + 32 3 821 14 12



*********************************************************************
The information in this email is confidential and is intended solely
for the addressee(s).
Access to this email by anyone else is unauthorised. If you are not
an intended recipient, you must not read, use or disseminate the
information contained in the email.
Any views expressed in this message are those of the individual sender,
except where the sender specifically states them to be the views of
The Capital Markets Company.

http://www.capitalmarketscompany.com
***********************************************************************

===========================================================================
To unsubscribe, send email to [EMAIL PROTECTED] and include in the body
of the message "signoff EJB-INTEREST".  For general help, send email to
[EMAIL PROTECTED] and include in the body of the message "help".

Reply via email to