The user specified as a definer ('xxx'@'%') does not exist

The user specified as a definer ('xxx'@'%') does not exist的解决办法
出现这个问题是因为从生产上dump了一份数据库文件下来,然后没有产生对应的帐号,解决方法

  1. 创建与xxx同名的帐户,密码也相同
  2. 进入mysql执行以下指令 以windows为例
mysql -uroot -proot
mysql>  grant all privileges on *.* to xxx@"%" identified by "yourpassword";
mysql> flush privileges;

然后用xxx帐户进入mysql,就会发现这些存储过程可以执行了

你可能感兴趣的:(The user specified as a definer ('xxx'@'%') does not exist)