how to know all mysql user code example
Example 1: see all users mysql
mysql> select host, user, password from mysql.user;
Example 2: mysql check user privileges
SHOW GRANTS FOR 'root'@'localhost';
mysql> select host, user, password from mysql.user;
SHOW GRANTS FOR 'root'@'localhost';