Question

How to create an user in MySQL (without using create user)?


Answer

INSERT INTO user (Host,User,Password) VALUES('localhost','username',PASSWORD('xxxxxx')); INSERT INTO db(Host,Db,User,Select_priv,Insert_priv,Update_priv,Delete_priv,Create_priv,Drop_priv) VALUES('localhost','dbname','username','Y','Y','Y','Y','Y','Y'); FLUSH PRIVILEGES;


Post Feedback

Latest

Popular