Grant Select, Insert, Update to a Tablespace

Mikayil Abdullayev picture Mikayil Abdullayev · Jun 1, 2011 · Viewed 89.2k times · Source

I've got a lot of tables in a tablespace, nearly 100. I have to grant Select, Insert, Update privileges on all those tables to a user. Is it possible? When I write:

GRANT USE OF TABLESPACE MYTABLESPACE TO USERNAME

I get oracle error "invalid or missing privilege"

Answer

Tony Andrews picture Tony Andrews · Jun 1, 2011

USE OF TABLESPACE is not a documented option, where did you find that?

You can do this to allow a user to create objects in a tablespace:

alter user username quota [amount] on mytablespace;

To grant select, insert, update and delete on objects you have to run a separate grant command for each table:

grant select, insert, update, delete on mytable1 to username;
....