1 2 3 4 5 6 7
| mysql -h host -P port -u username -p USE mysql; SELECT Host,User FROM user; DELETE FROM user WHERE User='username' AND Host='host'; GRANT ALL ON *.* TO 'username'@'host' IDENTIFIED BY 'password' WITH GRANT OPTION; GRANT select,create,drop,update,alter ON *.* TO 'username'@'host' IDENTIFIED BY 'password' WITH GRANT OPTION; FLUSH PRIVILEGES;
|