I created a user to only select/Read data from MySQL but I can still drop tables from database. what is wrong in this SQL script.
create user 'test'@'%' Identified by 'test!';
grant SELECT ON * . * TO 'test'@'%';
FLUSH PRIVILEGES;
I created a user to only select/Read data from MySQL but I can still drop tables from database. what is wrong in this SQL script.
create user 'test'@'%' Identified by 'test!';
grant SELECT ON * . * TO 'test'@'%';
FLUSH PRIVILEGES;
You need to connect to the database as root.
I also notice that the proper command should be
Meanwhile yours is
That is, you got too many spaces (this could be the dealbreaker).
Then just use the test user
And run an update query.
You should receive an error
You could also try to tell what exactly you're using: