ERROR 1133 (42000): Can't find any matching row in the user table

執行授權語句

和授權時提示:ERROR 1133 (42000): Can't find any matching row in the user table
mysql> grant select  on test.* to test@'192.168.56.8';
ERROR 1133 (42000): Can't find any matching row in the user table

後來發現是因爲數據庫中不存在這個test 用戶

解決方法:

1)創建test用戶

2)檢查數據庫用戶找到正確的用戶授權

查看用戶語法 select host,user from mysql.user;

改成對的用戶就可以了,然後執行刷新命令即可。
mysql> flush privileges;
Query OK, 0 rows affected (0.00 sec)

發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章