How to do it...

Grant access to the schema containing the table, as follows:

GRANT USAGE ON someschema TO somerole; GRANT SELECT, INSERT, UPDATE, DELETE ON someschema.sometable TO somerole; GRANT somerole TO someuser, otheruser;

Get PostgreSQL Administration Cookbook, 9.5/9.6 Edition now with O’Reilly online learning.

O’Reilly members experience live online training, plus books, videos, and digital content from 200+ publishers.