MySQL Forums
Forum List  »  Connector/ODBC

Problems with ODBC 3.51 driver
Posted by: T C
Date: April 25, 2007 01:34AM

I must access a MySql database out of ASP.NET. As I understood, ODBC is the most used technology for this task (?)

I downloaded "MySQL ODBC 3.51 driver."

Stupid question: I installed this driver on my local developer PC and not on the server in our network, where the MySQL-DB is running.
Is this right or wrong ?!

I wrote the following code:

class Program
{
static void Main(string[] args)
{
const string ConnStr = "Driver={MySQL ODBC 3.51 Driver};" +
"Server=192.<*******>;" +"Port=3306;"+
"Database=theo;" +
"User=root;" + "Password='';" + "Option=3";

using (System.Data.Odbc.OdbcConnection connection =
new System.Data.Odbc.OdbcConnection())
{
connection.ConnectionString = ConnStr;
connection.Open();
connection.Close();
}
}
}



Compiling goes without error, but when starting the code, I get the error:

ERROR [HY000] [MySQL][ODBC 3.51 Driver]Host 'THEO' is not allowed to connect to this MySQL server

The MySQL-DB has no passwords set.

Options: ReplyQuote


Subject
Written By
Posted
Problems with ODBC 3.51 driver
T C
April 25, 2007 01:34AM


Sorry, you can't reply to this topic. It has been closed.

Content reproduced on this site is the property of the respective copyright holders. It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.