继续得到" ERROR 1142(42000):SELECT命令被拒绝给用户&root;' @' localhost'对于表'用户' "

时间:2015-11-26 10:20:55

标签: mysql

我在MySQL数据库中以root身份登录,我收到以下错误:

ERROR 1142 (42000): SELECT command denied to user 'root'@'localhost' for table 'user'

当我尝试运行以下命令时:

mysql> select * from mysql.user\G

有关如何解决此问题的任何想法?

她可能会有所帮助:

1

mysql> select user();
+----------------+
| user()         |
+----------------+ 
| root@localhost |
+----------------+
1 row in set (0.00 sec)

2。

mysql> SHOW GRANTS FOR 'root'@'localhost';
+--------------------------------------------------------------------------+
| Grants for root@localhost                                                |
+--------------------------------------------------------------------------+
| GRANT USAGE ON *.* TO 'root'@'localhost' IDENTIFIED BY PASSWORD <secret> |
| GRANT ALL PRIVILEGES ON `wordpress`.`wordpress` TO 'root'@'localhost'    |
| GRANT PROXY ON ''@'' TO 'root'@'localhost' WITH GRANT OPTION             |
+--------------------------------------------------------------------------+
3 rows in set (0.00 sec)

0 个答案:

没有答案