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 [EMAIL PROTECTED] http://bugzilla.ximian.com/show_bug.cgi?id=79926 --- shadow/79926 2006-11-14 09:40:18.000000000 -0500 +++ shadow/79926.tmp.7816 2006-11-14 09:40:18.000000000 -0500 @@ -0,0 +1,109 @@ +Bug#: 79926 +Product: Mono: Class Libraries +Version: 1.1 +OS: All +OS Details: +Status: NEW +Resolution: +Severity: 160 One month +Priority: Blocker +Component: Sys.Data.SqlClient +AssignedTo: [EMAIL PROTECTED] +ReportedBy: [EMAIL PROTECTED] +QAContact: [EMAIL PROTECTED] +TargetMilestone: --- +URL: +Cc: +Summary: Unable to use System.Data.Common.DbXXX model with SqlClient + +Please fill in this template when reporting a bug, unless you know what you +are doing. +Description of Problem: + +Steps to reproduce the problem: +1. Make an .exe file from following C# code: + +using System; +using System.Collections.Generic; +using System.Text; +using System.Data.SqlClient; +using System.Data; +using System.Globalization; +using System.Data.Common; + +namespace Foss.InetAccessUserBalance +{ + public class MainClass + { + static int Main(string[] args) + { + try + { + if (args.Length != 1) + { + Console.WriteLine("Usage: Foss.InetAccessUserBalance +<MSSQL connection string>"); + return 1; + } + string connectionString = args[0]; + + //string connectionString = +"server=FMAIL;database=Inet;uid=sa;pwd="; + + DbConnection dbConnection = new +SqlConnection(connectionString); + dbConnection.Open(); + + try + { + using (DbTransaction tx = +dbConnection.BeginTransaction(IsolationLevel.Serializable)) + { + // ... + tx.Commit(); + Console.WriteLine("OK"); + } + } + finally + { + dbConnection.Close(); + } + } + catch (Exception e) + { + Console.Error.WriteLine("Error: " + e); + return 1; + } + return 0; + } + } +} + +2. Run executable with mono. Ensure to give connection string to working +MSSQL server as first command line argument. + +Actual Results: +Error: System.NotImplementedException: The requested feature is not +implemented. +in <0x0001d> System.Data.ProviderBase.DbConnectionBase:BeginDbTransaction +(IsolationLevel isolationLevel) +in <0x00011> System.Data.Common.DbConnection:BeginTransaction +(IsolationLevel isolationLevel) +in (wrapper remoting-invoke-with-check) +System.Data.Common.DbConnection:BeginTransaction (System.Data.IsolationLevel) +in <0x0014f> Foss.InetAccessUserBalance.MainClass:Main (System.String[] args) + + +Expected Results: +OK + +How often does this happen? +Always + +Additional Information: + This sample works with success on Microsoft .NET 2.0. Fails on Mono 1.1.13. + I have jumped into the code of +mcs/class/System.Data/System.Data.SqlClient/SqlConnection.cs. As far as I +can see the root of the problem is unimplemented methods +BeginDbTransaction, CreateDbParameter, CreateDbCommand inherited from +DbConnection. _______________________________________________ mono-bugs maillist - [email protected] http://lists.ximian.com/mailman/listinfo/mono-bugs
