| From: | Richard Huxton <dev(at)archonet(dot)com> |
|---|---|
| To: | dipti shah <shahdipti1980(at)gmail(dot)com> |
| Cc: | pgsql-general(at)postgresql(dot)org |
| Subject: | Re: Define permissions at database level |
| Date: | 2010-02-18 10:31:37 |
| Message-ID: | 4B7D1709.1060504@archonet.com |
| Views: | Whole Thread | Raw Message | Download mbox | Resend email |
| Thread: | |
| Lists: | pgsql-general pgsql-novice |
On 18/02/10 10:23, dipti shah wrote:
> Thanks Richard. That makes sense. If I want to restrict DROP for any table
> then do I need to REVOKE permissions individually on tables.
>
> Revoke DROP ON MyTable from PUBLIC;
>
> I want to avoid doing it so I am wondering if I can define/grant the
> permission at database level so that nousers can directly use any commands
> like CREATE, UPDATE, ALTER or DROP. They have to use stored procedure. They
> can only use SELECT. Nothing else.
Only table owners can drop them.
You can deny permission to a whole schema, but not set permissions on
everything in it in one go. However there are various shell-scripts and
plpgsql functions that let you set permissions on groups of tables in
one go. They should show up easily enough through googling.
--
Richard Huxton
Archonet Ltd
| From | Date | Subject | |
|---|---|---|---|
| Next Message | dipti shah | 2010-02-18 10:34:44 | Re: Define permissions at database level |
| Previous Message | Antonio Goméz Soto | 2010-02-18 10:28:21 | Re: define transaction within pg/psql. Necessary? |
| From | Date | Subject | |
|---|---|---|---|
| Next Message | dipti shah | 2010-02-18 10:34:44 | Re: Define permissions at database level |
| Previous Message | dipti shah | 2010-02-18 10:23:54 | Re: Define permissions at database level |