Access to Mysql database via the/net connection

Asked

Viewed 188 times

1

I am developing a system that will access the Mysql database only to query data. I referenced the mysql.data.dll and I’m using access through Mysqlconnection.

It turns out that the system is returning the following error:

Access Denied for user 'meuusuario....'

The interesting thing is that I can access the same database with the same user through Sqlyog, but I can not through . net.

It would be some configuration in the user inside Mysql to accept the access ?

  • 1

    Provide your connection class or @Silva routine

  • Thanks for the @Harry Potter reply. I’m new around here... How do I include my class without exceeding the size of the comment ?

  • You can edit your question by putting it at the right point and pressing the {} of the editor

  • This user has password?

  • If the database is running on an IP other than your application check if you can get external access to your database and if your user is allowed to access the database. And check the Mysql log. There is a question about Mysql access issues at http://answall.com/questions/17597/acesso-remoto-mysql-servor-amazon/22964#22964, you can find procedures for configuring Mysql for external access (if this is the case).

1 answer

1

Have you checked if Mysql is accepting connections from other hosts? There is a configuration in Mysql that allows it to be accessed only from the machine that is installed, or from other hosts.

It is important to check in the configuration (my.ini or my.cnf, depending on whether your installation is windows or Unix) and see if in the [mysqld] section the settings are correct.

Some parameters that may be interesting here are: bind-address (addresses that connection is allowed) and enable-named-pipe.

Browser other questions tagged

You are not signed in. Login or sign up in order to post.