anybody know how to make asp.net using mysqlserver ? Post Edited By Moderator (mjp) : 6/8/2007 12:49:35 AM GMT
Try using the MySQL connector library for .NET. http://mysql.org/downloads/connector/net/5.0.html Aristotle DiscountASP.NET www.DiscountASP.NET
Try referencing this kb article for a example of a connection string for .net to connect to MySQL using DSN.
Which KB article? Everytime I search .net MySQL and DSN -- I get lots of results, but they don't show me how to connect to mysql in .net using dsn This would save me from converting all of my MySqlCommand's -> OdbcCommand etcetc!! We're talking many hours if I can get MySQL's .net connector to work properly
OMG I'm so sorry I totally brain farted on that one. Here it is again. http://kb.discountasp.net/article.aspx?id=10085
Thanks, but that link is using ODBC and DSN. I need it to use this method of connection using MySql.Data.MySqlClient; ... MySqlConnection conn = new MySqlConnection("DSN={username}_mySqlConn;"); MySqlCommand myCommand = new MySqlCommand("usp_insertPhoto", conn); myCommand.CommandType = CommandType.StoredProcedure; MySqlParameter param; param = new MySqlParameter("_name", MySqlDbType.VarChar, 50); param.Value = fuAddPhoto.FileName; myCommand.Parameters.Add(param); However I read somewhere that DiscountASP.net doesn't support using MySql.Data.MySqlClient. Maybe if I include the dll in the project I can still reference it, I'll test I guess! Thx,
Can the .NET Connector take DSN instead of connection string? As I understand, the only way to connect to MySQL database on discountasp.net is via DSN. Or am I wrong there?
You should be able to just upload the data provider into the app root's bin directory. Bruce DiscountASP.NET www.DiscountASP.NET