Icon View Thread

The following is the text of the current message along with any replies.
Messages 1 to 1 of 1 total
Thread Transaction rollback
Sun, Sep 20 2020 9:49 AMPermanent Link

Roy Lambert

NLH Associates

Team Elevate Team Elevate

Tim

Can we have a cleanup option for rollback please. I was just caught by a table being left in insert state.  I'm referring to

Note
It is very important that you always ensure that the transaction is rolled back if there is an
exception of any kind during the transaction. This will ensure that the locks held by the transaction
are released and other sessions can continue to update data while the exception is dealt with.
Also, if you roll back a transaction it is always a good idea to refresh any open TEDBTable or
TEDBQuery components linked to the TEDBDatabase component involved in the transaction so
that they reflect the current data and not any data from the transaction that was just rolled back.
Along with refreshing, you should make sure that any pending inserts or edits for the TEDBTable
or TEDBQuery components are cancelled using the Cancel method before the transaction is rolled
back to ensure that the inserts or edits are not accidentally posted using the Post method after the
transaction is rolled back (unless that is specifically what you wish to do).

Or possibly change the name from Rollback to RollbackSomeStuffButNotEverythingThatWasDoneInTheTransaction Smiley


Roy Lambert
Image