How To Set MySQL Password ?
Posted by: chaokusc (
Date: June 06, 2006 10:30AM

I tried entering SET PASSWORD FOR 'root'@'%' = PASSWORD('newpassword'); but it did not work...

Enter password:
Welcome to the MySQL monitor. Commands end with ; or \g.
Your MySQL connection id is 6 to server version: 5.0.21-community-nt

Type 'help;' or '\h' for help. Type '\c' to clear the buffer.

mysql> SET PASSWORD FOR 'root'@'%' = PASSWORD('newpassword');
ERROR 1133 (42000): Can't find any matching row in the user table

any ideas ?

Options: ReplyQuote
Re: How To Set MySQL Password ?
Posted by: CyberSpatium (67.170.181.---)
Date: June 06, 2006 01:32PM

If MySQL cannot find the MySQL user table, then you have deleted that database from MySQL. MySQL needs the user database to manage permissions for your databases. You NEED this database. Since it seems you are not an experienced MySQL administrator and know how to restore your database, the best solution is to completely uninstall WAMP and reinstall it again. Make sure after you uninstall WAMP, and before you reinstall it again you delete this folder:

After you reinstall WAMP, follow these steps to setup a password for you MySQL root user. this is 100 times easier then using the MySQL Console.

1. Set password in Privilleges in phpMyAdmin from your Browser/Localhost.
Goto: localhost/phpmyadmin/
click on "Privileges" link
click on "edit Privileges" link for ROOT user
and set-up your password (change password) and click go

2. Set password in in /wamp/phpmyadmin.
Find and put your password in this line: $cfg['Servers'][$i]['password'] = '';
Change that line to: $cfg['Servers'][$i]['password'] = 'Your_New_Password_Here';

Restart Apache and MySQL for your new settings to take effect.

Post Edited (06-06-06 13:37)

WAMP Forum Admin

Web Development for Newbie's Blog - Check out my new blog. It is for web developers, and especially tailored for the web development newbie. If you are not fluent in “geek speak”, then this incredible resource is just you. And even if you are a web development pro, this is a great resource to check out some of the latest web development tips, news, tutorials, codes and more.

Options: ReplyQuote

Sorry, only registered users may post in this forum.