今天操作以root身份操作MySQL数据库的时候报出了这个异常:
Error updating database. Cause: java.sql.SQLException: The user specified as a definer ('root'@'%') does not exist
问了度娘解决了该问题,记录一下:
报这个异常是权限问题,授权 给 root 所有sql 权限即可:
mysql> grant all privileges on *.* to root@"%" identified by ".";
Query OK, 0 rows affected (0.00 sec)
mysql> flush privileges;
Query OK, 0 rows affected (0.00 sec)