Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

mysql access denied for user 'odbc'@'localhost' to database

Tags:

mysql

root

I installed MySql5.5 and set password during installation but when I try to use mysql from windows command prompt, I have get the error:

access denied for user 'odbc'@'localhost' to database password = 'YES'

I would like to change it back into "root@localhost" as well as to reset the password but I can't log in mysql.

How do I login to mysql with root?

like image 213
Mackintoast Avatar asked Jan 27 '12 22:01

Mackintoast


2 Answers

You're trying to use the mysql interactive shell? You can specify usernames at the command line:

c:\> mysql -u root -p

where

-u = specify username
-p = prompt for password
like image 102
Marc B Avatar answered Sep 28 '22 01:09

Marc B


I fixed this by implementing a little hacky solution. Downloaded hxd (hex editor) and searched for 'ODBC' (there should only be one match) and just changed it to 'root'.

like image 23
KoderMagic Avatar answered Sep 28 '22 02:09

KoderMagic