Login

Username

Password





Register   Reset password

This is a read-only archive of the forum.

# acidmind 2/9/2009 7:05 PM
Hello people!
I'm installing the Cuyahoga 1.5.2 version with MySQL (5.0) on my local machine (Windows XP) but when I try to run the app I get this error:

[InvalidOperationException: Connection must be valid and open]
MySql.Data.MySqlClient.MySqlCommand.CheckState() +157
MySql.Data.MySqlClient.MySqlCommand.ExecuteReader(CommandBehavior behavior) +14
MySql.Data.MySqlClient.MySqlCommand.ExecuteReader() +6
MySql.Data.MySqlClient.Driver.ShowWarnings(Int32 count) +332
MySql.Data.MySqlClient.NativeDriver.ReadEOF(Boolean readPacket) +146
MySql.Data.MySqlClient.NativeDriver.ReadFieldMetadata(Int32 count, MySqlField[]& fields) +80
MySql.Data.MySqlClient.CommandResult.Load() +221
MySql.Data.MySqlClient.MySqlDataReader.NextResult() +149
MySql.Data.MySqlClient.MySqlCommand.ExecuteReader(CommandBehavior behavior) +140
MySql.Data.MySqlClient.MySqlCommand.ExecuteReader() +6
MySql.Data.MySqlClient.Driver.Configure(MySqlConnection connection) +195
MySql.Data.MySqlClient.NativeDriver.Configure(MySqlConnection connection) +10
MySql.Data.MySqlClient.MySqlConnection.Open() +187
NHibernate.Connection.DriverConnectionProvider.GetConnection() +59
NHibernate.Impl.SessionFactoryImpl.OpenConnection() +29

[ADOException: cannot open connection]
NHibernate.Impl.SessionFactoryImpl.OpenConnection() +83
NHibernate.Impl.ConnectionManager.GetConnection() +51
NHibernate.Impl.BatcherImpl.Prepare(IDbCommand cmd) +42
NHibernate.Impl.BatcherImpl.ExecuteReader(IDbCommand cmd) +24
NHibernate.Loader.Loader.GetResultSet(IDbCommand st, RowSelection selection, ISessionImplementor session) +182
NHibernate.Loader.Loader.DoQuery(ISessionImplementor session, QueryParameters queryParameters, Boolean returnProxies) +175
NHibernate.Loader.Loader.DoQueryAndInitializeNonLazyCollections(ISessionImplementor session, QueryParameters queryParameters, Boolean returnProxies) +56
NHibernate.Loader.Loader.DoList(ISessionImplementor session, QueryParameters queryParameters) +37
NHibernate.Loader.Loader.ListUsingQueryCache(ISessionImplementor session, QueryParameters queryParameters, ISet querySpaces, IType[] resultTypes) +144
NHibernate.Loader.Loader.List(ISessionImplementor session, QueryParameters queryParameters, ISet querySpaces, IType[] resultTypes) +65
NHibernate.Hql.Classic.QueryTranslator.List(ISessionImplementor session, QueryParameters queryParameters) +20
NHibernate.Impl.SessionImpl.Find(String query, QueryParameters parameters, IList results) +210
NHibernate.Impl.SessionImpl.Find(String query, QueryParameters parameters) +46
NHibernate.Impl.QueryImpl.List() +114
NHibernate.Impl.AbstractQueryImpl.UniqueResult() +7
Cuyahoga.Core.DataAccess.SiteStructureDao.GetSiteAliasByUrl(String url) +201
InvocationGetSiteAliasByUrl_2.InvokeMethodOnTarget() +59
Castle.DynamicProxy.AbstractInvocation.Proceed() +25
Castle.Facilities.AutomaticTransactionManagement.TransactionInterceptor.Intercept(IInvocation invocation) +80
Castle.DynamicProxy.AbstractInvocation.Proceed() +55
ISiteStructureDaoProxy1c59b1c2f554487b90d570c13edaaa23.GetSiteAliasByUrl(String url) +127
Cuyahoga.Core.Service.SiteStructure.SiteService.GetSiteAliasByUrl(String url) +10
Cuyahoga.Web.UI.PageEngine.OnInit(EventArgs e) +51
System.Web.UI.Control.InitRecursive(Control namingContainer) +321
System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +692
# martijnb 2/9/2009 10:30 PM
Could you post your connectionstring?
# acidmind 2/10/2009 3:06 PM
Hello martijnb,
I really dont know what is happening, because I connect with success when I use the MySQL Command Line or MySql Administrator.

My connection string (located at properties.config) is:
server=localhost;database=cuyahoga;uid=root;pwd=pass;

Sorry, but the forum dont accept all the code from properties.config. :(



# martijnb 2/11/2009 8:49 AM
Hmmm, the connection string looks alright.
If I do a google search on the error message, I can't find anything that points to the right direction.

Do you perhaps have MySQL connector installed in the GAC or something?
# acidmind 2/14/2009 6:13 PM
Hi martijnb,
The MySql.Data is already in the GAC.
I have installed (and reinstalled) the MySQL Connector 5.2.5 many times.

I'm installing the Cuyahoga (binaries), because in this machine I don't have the VS installed.

I really don't know what's happening!

# martijnb 2/15/2009 1:38 PM
And what happens if you uninstall MySQL connector?
In the Cuyahoga download, we already include an (old) version of MySQL connector that works. We had to do this because, in the past, different versions of MySQL connector caused several strange issues.
# acidmind 2/16/2009 12:30 AM
martijnb,
I removed the connector and worked perfect!!! O_o

Thank you very, very much!!! :)