Link to home
Start Free TrialLog in
Avatar of MainMa
MainMa

asked on

mysql_fix_privilege_tables problem

I have the problem with MySQL or PHPMyAdmin under Windows XP :

When I want to see, with PHPMyAdmin, the privileges, it shows me the next error :
--------------------
Warning: Your privilege table structure seems to be older than this MySQL version!
Please run the script mysql_fix_privilege_tables that should be included in your MySQL server distribution to solve this problem!
--------------------

First, I haven't got any mysql_fix_privilege_tables.sql file, and even the "scripts" folder. So, after reading

https://www.experts-exchange.com/questions/20853977/I-don't-have-the-mysql-fix-privilege-tables-sql-file.html

I created the ".../MySQL/scripts/mysql_fix_privilege_tables.sql" file. Then, I've executed the script through MySQL console. All's Ok, except PHPMyAdmin shows the same error...
What is the problem ?


PS. I have Windows XP, MySQL 5.0 and PHPMyAdmin 2.7.0-pl1
Avatar of MainMa
MainMa

ASKER

I've just tried to use the mysql_fix_privilege_tables.sql file from mysql-noinstall-5.0.17-win32.zip. It returns about 40 identical errors "ERROR 1046 (3D000): No database selected", and PHPMyAdmin shows always the same error.
ASKER CERTIFIED SOLUTION
Avatar of todd_farmer
todd_farmer
Flag of United States of America image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of MainMa

ASKER

Ok ! Now, it works.

For all people having the same problem :

In MySQL documentation, you can find :
--------------------
On Windows systems, MySQL distributions include a mysql_fix_privilege_tables.sql SQL script that you can run using the mysql client. For example, if your MySQL installation is located at C:\Program Files\MySQL\MySQL Server 5.0, the commands look like this:

C:\> C:\Program Files\MySQL\MySQL Server 5.0\bin\mysql -u root -p mysql
mysql> SOURCE C:/Program Files/MySQL/MySQL Server 5.0/scripts/mysql_fix_privilege_tables.sql
--------------------



So it doesn't work (for me). The right way (which worked for me) is :
--------------------
mysql.exe --force mysql < C:/Program Files/MySQL/MySQL Server 5.0/scripts/mysql_fix_privilege_tables.sql -u root -p
--------------------