1

I have been used following command but it was not working.

GRANT ALL PRIVILEGES ON *.* TO ROOT@LOCALHOST IDENTIFIED BY "my_password";
Dharman
  • 30,962
  • 25
  • 85
  • 135
parmeshawar
  • 13
  • 1
  • 1
  • 5
  • 2
    possible useful if you are locked out of your database: http://stackoverflow.com/questions/1708409/how-to-start-mysql-with-skip-grant-tables – Paul Aug 11 '13 at 10:19

1 Answers1

1

You are not connected (in the way of a login & username) to the database, you need to connect. depending on the way you acces the database. in command line, you can use this:

mysql -pYourpassword -u username
Vincent Duprez
  • 3,772
  • 8
  • 36
  • 76