Re: Transaction when client shutdown

Tech-Archive recommends: Repair Windows Errors & Optimize Windows Performance

From: Hugo Kornelis (hugo_at_pe_NO_rFact.in_SPAM_fo)
Date: 12/07/04


Date: Tue, 07 Dec 2004 01:21:24 +0100

On Mon, 6 Dec 2004 11:31:17 -0500, David Gugick wrote:

>Hugo Kornelis wrote:
>> On Fri, 3 Dec 2004 13:45:04 +0200, mttc wrote:
>>
>>> Hugo
>>>
>>> I'm sorry about late, I hope you see my respond.
>>> I check your scenario, and I find that you right.
>>> But I have another scenario. I build some stupid query
>>> On NorthWind to illustrate it:
>>
>> Hi mttc,
>>
>> Thanks for the illustration. I didn't realise that you were talking
>> about cancelling the query - I thought your questions were about
>> killing a process or dropping a connection.
>>
>> As your script shows (and David indicates), cancelling execution from
>> QA is doesn't kill the connection and doesn't kill the process, so
>> there is indeed no automati commit or rollback of open transactions.
>> The transaction remains open and any locks are held until the
>> transaction ends.
>>
>> Best, Hugo
>
>I always thought QA did the rollback for you. I guess I need to do some
>testing... back later with results.

Hi David,

I must admit it was an eye-opener to me as well. I also was under the
impression that cancelling execution in QA implies a rollback. I'm glad I
found it out THIS way! <g>

Best, Hugo

-- 
(Remove _NO_ and _SPAM_ to get my e-mail address)


Relevant Pages

  • Re: Nested Transactions
    ... then it is possible that transaction was opened ... against one connection and rollback called against another one. ... Trying this with ADO and SQLOLEDB, ... > Rollback doesn't work, saying, there is no corresponding BEGIN statement. ...
    (microsoft.public.data.ado)
  • Re: Using a Transaction with a SqlDataSource
    ... The return from this stored procedure determines if Icommit or rollback. ... "Transaction count after EXECUTE indicates that a COMMIT or ROLLBACK ... The e.Command.Transaction.Rollbackshould be placed in the scope of the Catch, with a possible check to see if the connection is Open and close the connection before you Throw to leave the routine. ...
    (microsoft.public.dotnet.languages.csharp)
  • Re: DB Wrapper, IDisposable richtig implementiert?
    ... In der Methode BeginTransaction() könnte ich ... so solltest Du auch Commit und Rollback implementieren. ... Und diese anstatt der Connection Instanz zu verwenden ... // die Connection und Transaction zusammenfasst ...
    (microsoft.public.de.german.entwickler.dotnet.csharp)
  • Re: Rollback timeout ???
    ... When you call the BeginTransaction API method we will mark this connection ... When you call the Transaction.Commit or Rollback we will unmark the ... If you close a connection that is marked as having a transaction active we ...
    (microsoft.public.dotnet.framework.adonet)
  • Re: Classic Nest SP with Transaction Question
    ... enclosing transaction or should begin and commit/rollback its own ... > I echo Ron's points and also have been using an approach very similar to> Tom's method of using a SAVE PT instead of starting a new TRANSACTION if the> ChildSP is called from the ParentSP. ... > The ParentSp now has to ROLLBACK everything up to that point. ... As Ron> mentioned, the ParentSP may have called many child SPs, and performed many> updates up to this point, and all of these need to be rolled back. ...
    (microsoft.public.sqlserver.programming)