Great post. really helful. Thanks mate!
El miércoles, 22 de septiembre de 2010 00:32:58 UTC-3, El escribió: > > Hi, > > I'm testing out Linq to MySql. I downloaded the latest MySQL > Connector/Net from the MySQL site. I have a simple mysql database > with 1 table in the schema. > > When I executed the command below: > > sqlmetal /provider:MySql /server:localhost /database:MySqlSampleDb / > user:hansel /password:rpt4wr5 /pluralize /code=mysqlsampledb.cs > > I get this as the output and I don't get any file. > > DbLinq Database mapping generator 2008 version 0.20 > for Microsoft (R) .NET Framework version 3.5 > Distributed under the MIT licence (http://linq.to/db/license) > > >>> Reading schema from MySQL database > sqlmetal: Client does not support authentication protocol requested by > server; consider upgrading MySQL client > > I have the latest Mysql.Data.dll in my GAC. I even copied the file in > the local directory where I run sqlmetal. I saw some links that > suggested adding the /databaseConnectionProvider. So I did and change > it as below. I also added the debug option to get the stack trace. > > sqlmetal /provider:MySql / > databaseConnectionProvider="MySql.Data.MySqlConnection, MySql.Data" / > server:localhost /database:MySqlSampleDb /user:hansel / > password:rpt4wr5 /debug /pluralize /code=mysqlsampledb.cs > > This is what I got... > > DbLinq Database mapping generator 2008 version 0.20 > for Microsoft (R) .NET Framework version 3.5 > Distributed under the MIT licence (http://linq.to/db/license) > > >>> Reading schema from DBML file > '/databaseConnectionProvider=MySql.Data.MySqlConnection, MySql.Data' > sqlmetal: Could not find file "/ > databaseConnectionProvider=MySql.Data.MySqlConnection, MySql.Data". > > I even copied the DLL locally and installed it in the GAC. Below is > the trace output with /debug: > > sqlmetal: System.IO.FileNotFoundException: Could not find file "/ > databaseConnectionProvider=MySql.Data.MySqlConnection, MySql.Data". > File name: '/databaseConnectionProvider=MySql.Data.MySqlConnection, > MySql.Data' > at System.IO.FileStream..ctor (System.String path, FileMode mode, > FileAccess access, FileShare share, Int32 bufferSize, Boolean > anonymous, FileOptions options) [0x00000] in <filename unknown>:0 > at System.IO.FileStream..ctor (System.String path, FileMode mode, > FileAccess access, FileShare share) [0x00000] in <filename unknown>:0 > at (wrapper remoting-invoke-with-check) System.IO.FileStream:.ctor > (string,System.IO.FileMode,System.IO.FileAccess,System.IO.FileShare) > at System.IO.File.OpenRead (System.String path) [0x00000] in > <filename unknown>:0 > at DbMetal.Generator.Implementation.Processor.ReadSchema > (DbMetal.Parameters parameters, System.String filename) [0x00000] in > <filename unknown>:0 > at DbMetal.Generator.Implementation.Processor.ReadSchema > (DbMetal.Parameters parameters, ISchemaLoader& schemaLoader) [0x00000] > in <filename unknown>:0 > at DbMetal.Generator.Implementation.Processor.ProcessSchema > (DbMetal.Parameters parameters) [0x00000] in <filename unknown>:0 > > I don't know what else to try. Any help appreciated. > > -- You received this message because you are subscribed to the Google Groups "DbLinq" group. To view this discussion on the web visit https://groups.google.com/d/msg/dblinq/-/mwpmTdzvfxgJ. To post to this group, send email to [email protected]. To unsubscribe from this group, send email to [email protected]. For more options, visit this group at http://groups.google.com/group/dblinq?hl=en.
