How the mysql database sets user permissions, such as having 100 tables. I want to set the user to read only 99 of these tables. There is also a table that does not have access.

how the mysql database sets user permissions, such as 100 tables. I want to set the user to read only 99 of these tables. There is also a table that does not have access. -sharp-sharp-sharp problem description

the environmental background of the problems and what methods you have tried

related codes

/ / Please paste the code text below (do not replace the code with pictures)

what result do you expect? What is the error message actually seen?

Nov.02,2021

if it is convenient, separate 99 tables and 1 table into two schema, and only authorize the schema permission of 99 tables to the user. Otherwise, let's use


grant statement to learn about


.

if it is inconvenient, grant all the tables under the database to the user first;
then revoke the table that you do not have access to separately.

for more information on the usage of grant and revoke, please refer to mysql Authorization and revocation

Menu