ALTER USER 'root'@'localhost' IDENTIFIED BY 'password';
CREATE USER 'root'@'%' IDENTIFIED BY 'test123!';
drop user '用户名';
GRANT ALL PRIVILEGES ON *.* TO 'root'@'%' WITH GRANT OPTION;
grant select,insert on 数据库名.表名 to '用户名';
grant select,insert,delete,create,drop,update on 数据库名.* to '用户名';
revoke insert on 数据库名.表名 from '用户名';
FLUSH PRIVILEGES;
SELECT host, user FROM mysql.user WHERE user='root';
CREATE USER 'username'@'%' IDENTIFIED BY 'password';
GRANT ALL PRIVILEGES ON *.* TO 'username'@'%';
ALTER USER 'root'@'%' IDENTIFIED BY 'your_password';
FLUSH PRIVILEGES;
mysql> create database wordpress;