[Mono-bugs] [Bug 60034][Nor] New - Subsequent calls to SqlTransaction.Rollback() throws InvalidOperationException

bugzilla-daemon@bugzilla.ximian.com bugzilla-daemon@bugzilla.ximian.com
Fri, 11 Jun 2004 11:54:30 -0400 (EDT)


Please do not reply to this email- if you want to comment on the bug, go to the
URL shown below and enter your comments there.

Changed by cmyers@austin.rr.com.

http://bugzilla.ximian.com/show_bug.cgi?id=60034

--- shadow/60034	2004-06-11 11:54:30.000000000 -0400
+++ shadow/60034.tmp.8357	2004-06-11 11:54:30.000000000 -0400
@@ -0,0 +1,50 @@
+Bug#: 60034
+Product: Mono: Class Libraries
+Version: unspecified
+OS: 
+OS Details: Windows XP SP1
+Status: NEW   
+Resolution: 
+Severity: 
+Priority: Normal
+Component: Sys.Data.SqlClient
+AssignedTo: rodrigo@novell.com                            
+ReportedBy: cmyers@austin.rr.com               
+QAContact: mono-bugs@ximian.com
+TargetMilestone: ---
+URL: 
+Cc: 
+Summary: Subsequent calls to SqlTransaction.Rollback() throws InvalidOperationException
+
+Description of Problem:
+If you call rollback on a transaction that's already been rolled back, or 
+if you Dispose the transaction, 
+you'll get an InvalidOperationException.
+
+This might not necessarily be a "bug" per se, but it's different than the 
+behavior in the MS .NET SqlTransaction,
+so it makes for inconsistencies and pain when trying to compile across 
+frameworks.
+
+Steps to reproduce the problem:
+1. Open a transaction
+2. call Rollback
+3. call Rollback again.
+
+Actual Results:
+InvalidOperationException
+
+Expected Results:
+nothing, the 2nd rollback call should do nothing.
+
+How often does this happen? 
+Every time
+
+Additional Information:
+
+Here's an example:
+
+using( SqlTransaction trans = conn.BeginTransaction() )
+{
+    trans.Rollback();
+}