Link to home
Start Free TrialLog in
Avatar of formadmirer
formadmirerFlag for United States of America

asked on

MySQL Permission 'Select Only'

I have a situation where I would like for someone to be able to connect to a database and issue a query to select data only. Nothing else.
I'm assuming, for example when using c-Panel, that this is accomplished by simply choosing 'select' under user permissions for the db.

But would I need to provide any other permission other than 'select'?

Here are the choices available in the c-Panel MySQL user permissions:
ALTER
CREATE
CREATE ROUTINE
CREATE TEMPORARY TABLES
CREATE VIEW
DELETE
DROP
EXECUTE
INDEX
INSERT
LOCK TABLES
REFERENCES
SELECT
SHOW VIEW
UPDATE

Obviously I don't want to permit any 'create', 'drop', 'delete', 'insert' or 'update', but what about Index, Lock Tables, Execute and References.

Would it be necessary to grant any of these to perform a simple select query against the db?

Thanks!
ASKER CERTIFIED SOLUTION
Avatar of arnold
arnold
Flag of United States of America image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
SOLUTION
Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of formadmirer

ASKER

I conducted some tests and found that I only need to allow select. I appreciate your replies - thanks!