Re: newbie : setting access for users in a web enviroment - Mailing list pgsql-general

From robert mena
Subject Re: newbie : setting access for users in a web enviroment
Date
Msg-id 528f47680512240441t7350e894u30dd32deaa207b10@mail.gmail.com
Whole thread Raw
In response to Re: newbie : setting access for users in a web enviroment  (Peter Eisentraut <peter_e@gmx.net>)
Responses Re: newbie : setting access for users in a web enviroment
List pgsql-general
Hi,

thanks for the reply.

I've already read the docs.  I am using 8.0.5 btw.

One of the things I am confused is how can I give the privileges to
the database without having to know the specific tables.

The grant command when applied to a database simply mentions CREATE so
the user can create tables.  But when applied to tables, where I can
specify specific privileges I need to know the table...

If I'd need to define a user with SELECT privileges to all tables in
my test database, how could I do that?

A simple example would be fine.

On 12/23/05, Peter Eisentraut <peter_e@gmx.net> wrote:
> Am Freitag, 23. Dezember 2005 22:06 schrieb robert mena:
> > GRANT CREATE,REFERENCES ON DATABASE test TO testadm;
> >
> > \z
> > Access privileges for database "test"
> >  Schema | Name | Type | Access privileges
> > --------+------+------+-------------------
> >
> > How can I specify that the user testadm can perform those actions to this
> > database?
>
> For one thing, the command \z shows table privileges, so the empty table
> above
> is not surprising.  pg_database would give you better information.
>
> Second, the privilege type REFERENCES does not exist for databases, only for
> tables, so the command you executed does not make sense.
>
> I suggest you peruse the GRANT manual page again.
>

pgsql-general by date:

Previous
From: Bruno Wolff III
Date:
Subject: Re: query for a time interval
Next
From: markc@renta.net
Date:
Subject: Login username char length