Sometimes you have to make a lot of grants for a specific user. It could be a pain in the neck with a lot of copy/paste.

Here goes a little loop to ease it all.


begin
for rec in (select object_name from user_objects where object_name like 'PREFIX_%' and object_type = 'TABLE') loop
execute immediate 'grant select on ' || rec.object_name || ' to THE_USER';
end loop;
end;