This thread looks to be a little on the old side and therefore may no longer be relevant. Please see if there is a newer thread on the subject and ensure you're using the most recent build of any software if your question regards a particular product.
This thread has been locked and is no longer accepting new posts, if you have a question regarding this topic please email us at support@mindscape.co.nz
|
We have two remote MySQL databases server. One is ver. 5.0.x and the other is 5.1.x. Today moving a schema from the second to the first we have obtained the following problem: "Table 'xxxx.xxx' doesn't exist" but the table exist and it is possible to SELECT/INSERT/UPDATE over it using Query Analyzer or other tools. The following is the stacktrace: at MySql.Data.MySqlClient.MySqlStream.ReadPacket() at MySql.Data.MySqlClient.NativeDriver.GetResult(Int32& affectedRow, Int32& insertedId) at MySql.Data.MySqlClient.Driver.GetResult(Int32 statementId, Int32& affectedRows, Int32& insertedId) at MySql.Data.MySqlClient.Driver.NextResult(Int32 statementId) at MySql.Data.MySqlClient.MySqlDataReader.NextResult() at MySql.Data.MySqlClient.MySqlCommand.ExecuteReader(CommandBehavior behavior) at MySql.Data.MySqlClient.MySqlCommand.ExecuteDbDataReader(CommandBehavior behavior) at System.Data.Common.DbCommand.System.Data.IDbCommand.ExecuteReader() at ...() at ..(IUnitOfWork , IDbCommand , ) at ..(IUnitOfWork , IDbCommand ) at .\b..ctor(IUnitOfWork , IEnumerable`1 ) at Mindscape.LightSpeed.Data.DataProviderAdapter.(IUnitOfWork , IEnumerable`1 , ProviderOptions ) at ..(TypeModel , Query , IList ) at ..(UnitOfWorkBase , TypeModel , Query , IList ) at ..(Query , TypeModel , IList ) at ..(Query , IList ) at Mindscape.LightSpeed.UnitOfWork.Find(Query query, IList results) at Mindscape.LightSpeed.UnitOfWorkBase.Find(Query query) at Mindscape.LightSpeed.Linq.Plan.SingleQueryPlan.ExecuteImmediate(IUnitOfWork unitOfWork, Type returnType) at Mindscape.LightSpeed.Linq.LinqQueryProvider.Execute(Expression expression) at Mindscape.LightSpeed.Linq.LinqQueryProvider.System.Linq.IQueryProvider.Execute[S](Expression expression) at System.Linq.Queryable.SingleOrDefault[TSource](IQueryable`1 source, Expression`1 predicate)
|
|
|
This is with the same client code, right? If so then this may be a case-sensitivity issue -- perhaps your 5.0.x box is set up to be case-insensitive about table names and your 5.1 box is set up to be case-sensitive? You may also find it useful to capture the exact SQL that LightSpeed is sending (unitOfWork.Context.Logger = new TraceLogger()) and try running that in your MySQL tools. If you have changed any client settings then you can also use this technique to verify that you have the same configuration in both cases (e.g. PluralizeTableNames, QuoteIdentifiers) by comparing the generated SQL. |
|
|
You are right. I have activated the logger and see immediately the problem. Thanks for help. Fausto |
|
|
Hi Ivan, I solve my problems after your answer, filling by hand the field TableName on property window of each table. But I discovered that the problem was caused from LightSpeed Designer. I try to create from scratch the db design directly from the schema on MySQL v.5.0 installed on Linux Server with the following vars: - lower_case_file_system = ON
- lower_case_table_names = 1 and I notice that in the designer some tables had the property TableName filled and other not, randomly.
|
|