select host,user,password from mysql.user
2.删除用户
mysql>Delete FROM user Where User='用户名' and Host='上图有个host列表所示'//删除用户
例:mysql>Delete FROM user Where User='yl' and Host='localhost'
mysql>flush privileges//刷新权限
mysql>drop database ylDB//删除用户的数据库
查看MYSQL数据库中所有用户SELECT DISTINCT CONCAT('User: ''',user,'''@''',host,'''') AS query FROM mysql.user
欢迎分享,转载请注明来源:内存溢出
评论列表(0条)