MariaDB [(none)]> drop user cr; ERROR 1396 (HY000): Operation DROP USER failed for 'cr'@'%'
- 首先查看mysql.user表中是否存在该用户
- 如果存在,更新权限
MariaDB [(none)]> flush privileges;
- 重新执行删除操作(注意删除的时候要写全称)
MariaDB [(none)]> drop user 'cr'@'localhost';
- 查看用户表
MariaDB [(none)]> SELECT DISTINCT CONCAT('User: ''',user,'''@''',host,''';') AS query FROM mysql.user;
欢迎关注我的公众号:小秋的博客
CSDN博客:https://blog.csdn.net/xiaoqiu_cr
github:https://github.com/crr121
联系邮箱:rongchen633@gmail.com
有什么问题可以给我留言噢~