Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chriss Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

releasing locks in nested transaction

Status
Not open for further replies.

jel

Programmer
Feb 17, 2002
349
NL
In the app I'm working on, MTS starts a transaction, then lots of objects do lots of things, and finally the transaction is committed.
There is a great risk of running into deadlocks that way, but at the moment an even worse problem is: users have to wait until locks set by other user(s) are released, this may take many seconds and result in time-outs.
The whole thing pivots around one single function that updates and reads a specific record.
This function needs to be in a transaction, as it is absolutely necessary that no two users update the same values. However, after reading the result, the transaction can be closed, as no roll-back is ever required. Locks set by a nested transaction however are only released when all of the transaction is committed.
Is there a way to release locks within a nested transaction, and have the rest of the transaction committed as usual, at the end of the whole thing?

 
OK that's just use another component with the MTS-setting 'requires new transaction'?
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top