4

I want to create new user and want to give them specific permission like inset, update and delete. But how to create new user and give them permission i don't know.

Any help please.

5

It would be something like this :

GRANT SELECT, INSERT, DELETE ON database TO username@'localhost' IDENTIFIED BY 'password';

To see a list of the privileges that have been granted to a specific user:

select * from mysql.user where User='username';

OR

CREATE USER 'newuser'@'localhost' IDENTIFIED BY 'password';
GRANT ALL PRIVILEGES ON * . * TO 'newuser'@'localhost';
1
  • Yes it works, thank you so much. Let me try another one also. Jan 8 '14 at 8:32
1

You can use GRANT syntax to give user permission: http://dev.mysql.com/doc/refman/5.0/en/grant.html

For example if you would like to give SELECT permission on TEST database for myUser then:

GRANT SELECT ON Test. TO 'myUser'@'%';*

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.