1

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

GRANT ALL PRIVILEGES ON *.* TO ROOT@LOCALHOST IDENTIFIED BY "my_password";
Dharman
  • 26,923
  • 21
  • 73
  • 125
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,632
  • 6
  • 31
  • 73