MY SQL error 'Connection must be opened' (C# ,ASP.net ,MY Sql ,MY SQL direct.net drivers version 2.8)
Posted: Wed 04 May 2005 21:57
I am running few queries in a transaction in an ASP.net web application using C# and MYSQL and MY SQL DIRECT.net Drivers.When i begin a transaction i open up a connection in C# code and use the same connection string for all the other queries within the transaction.At the end of the transaction i close the connection.
I am running into an error that occurs randomly....Sometimes mid way between the transaction i get Folowing error Connection must be opened.
I am surprised as to why sometimes the entire transaction goes through smoothly whereas sometimes i get error 'Connection must be opened'....as the database connection is closed only at end of transaction.
Is it a driver related issue.Please anybody can let me know as to why its happening
I am running windows 2003 /My sql version 4.0.1 /Drivers :MySQlDirect.net 2.8 version
ERROR IS :
Connection must be opened.
at
CoreLab.MySql.MySqlConnection.i()
at CoreLab.MySql.MySqlCommand.a(CommandBehavior A_0, IDisposable A_1, Int32 A_2,
Int32 A_3)
at CoreLab.Common.DbCommandBase.b(CommandBehavior A_0)
at CoreLab.Common.DbCommand.ExecuteReader()
at CoreLab.Common.DbCommandBase.ExecuteNonQuery()
at CFarmsLib.DataAccess.DataAccessBase.ExecuteNonQuery(String cmdText)
I am running into an error that occurs randomly....Sometimes mid way between the transaction i get Folowing error Connection must be opened.
I am surprised as to why sometimes the entire transaction goes through smoothly whereas sometimes i get error 'Connection must be opened'....as the database connection is closed only at end of transaction.
Is it a driver related issue.Please anybody can let me know as to why its happening
I am running windows 2003 /My sql version 4.0.1 /Drivers :MySQlDirect.net 2.8 version
ERROR IS :
Connection must be opened.
at
CoreLab.MySql.MySqlConnection.i()
at CoreLab.MySql.MySqlCommand.a(CommandBehavior A_0, IDisposable A_1, Int32 A_2,
Int32 A_3)
at CoreLab.Common.DbCommandBase.b(CommandBehavior A_0)
at CoreLab.Common.DbCommand.ExecuteReader()
at CoreLab.Common.DbCommandBase.ExecuteNonQuery()
at CFarmsLib.DataAccess.DataAccessBase.ExecuteNonQuery(String cmdText)