mysql好好的结果突然查库查表不行
> show databases; ERROR 1449 (HY000): The user specified as a definer ('mysql.infoschema'@'localhost') does not exist
试了许多办法之后下面一种方式对我有用,希望能帮助到大家
先照常用root
用户登录到mysql
mysql -u root -p
然后
DROP USER 'mysql.infoschema'@'localhost';
再次创建这个用户
CREATE USER 'mysql.infoschema'@'localhost' IDENTIFIED BY 'yourpassword';
授予它权限
GRANT SELECT ON *.* TO `mysql.infoschema`@`localhost`; FLUSH PRIVILEGES;
之后再次show databases;
就没问题了