Tim
Tim

Reputation: 101

Granting DML and DBA Privileges

I have a data table called Employees. Say I want to grant only all DML privileges to an user called Shelby. Does this statement work?

grant all on employees to shelby;

But doesn't that grant a lot more than just DML privileges? What is the proper way to do it?

Now lets say I want to grant only all DBA privileges to Shelby. I wrote the statement:

grant dba on employees to shelby;

But this returns the error "missing or invalid privilege". How do I fix this?

Upvotes: 0

Views: 6041

Answers (1)

Nicola
Nicola

Reputation: 314

If you want to give "system" privileges ("global" privileges)

grant dba to shelby;

if you want to give "object" privileges (on particular objects, tables, views, etc..)

grant select on employees to shelby;
grant insert on employees to shelby;
grant update, alter on employees to shelby;

Upvotes: 1

Related Questions