From: | Bruno Wolff III <bruno(at)wolff(dot)to> |
---|---|
To: | Fernan Aguero <fernan(at)iib(dot)unsam(dot)edu(dot)ar> |
Cc: | pgsql-general(at)postgresql(dot)org |
Subject: | Re: grant privileges across schemas |
Date: | 2006-04-19 17:39:19 |
Message-ID: | 20060419173919.GA15999@wolff.to |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-general |
On Wed, Apr 19, 2006 at 09:29:50 -0300,
Fernan Aguero <fernan(at)iib(dot)unsam(dot)edu(dot)ar> wrote:
>
> The following works, but I'm not sure about the consequences
> of granting USAGE to a schema, as the documentation is
> not clear, IMO : "For schemas, allows access to objects
> contained in the specified schema (assuming that the
> objects' own privilege requirements are also met).
> Essentially this allows the grantee to "look up" objects
> within the schema."
> mydb=> GRANT USAGE ON SCHEMA myschema TO readonly;
> GRANT
>
> After doing this, how do I give SELECT privilege to this
> user for all tables of this schema?
Granting access to a schema allows use of that schema. It does not grant
access to objects contained in the schema. You will need to do a grant for
each object in addition to what you are already doing. You will probably want
to write a script or function to do it, as there isn't a built in command
to do grants to multiple objects.
From | Date | Subject | |
---|---|---|---|
Next Message | Shoaib Mir | 2006-04-19 18:59:10 | Error while adding a column |
Previous Message | jonathan ramirez | 2006-04-19 17:27:46 | consulta SELECT FOR UPDATE |