Managing User Accounts
The MySQL administrator should know how to set up MySQL user accounts by specifying which users can connect to the server, where they can connect from, and what they can do while connected. MySQL 3.22.11 introduced two statements that make this task much easier: The GRANT statement creates MySQL users and specifies their privileges, and the REVOKE statement removes privileges. These two statements act as a front end to the grant tables in the mysql database and provide an alternative to manipulating the contents of those tables directly. The GRANT and REVOKE statements affect four tables:
Grant Table | contents |
---|---|
user | Users who can connect to the server and any global privileges they have |
db | Database-level privileges |
tables_priv ... |
Get MySQL now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.