Re: Question about Privileges

Поиск
Список
Период
Сортировка
От John R Pierce
Тема Re: Question about Privileges
Дата
Msg-id 49B99087.1050506@hogranch.com
обсуждение исходный текст
Ответ на Question about Privileges  (Jack W <dbdevelop2000@gmail.com>)
Список pgsql-general
Jack W wrote:
>
> I also find that if I only grant privileges on database to dbuser as
> below, without granting privileges on Schema and table to dbuser,
> dbuser still can not do SELECT on the tables.
> mydb=# grant all privileges on Database mydb to dbuser;
>
> Is there any simple way to grant All privileges to dbuser on all the
> 10 tables?

the simplest way is to make dbuser the OWNER of the database, and have
him create all the tables too, then he automatically has full rights to it.

there are also various scripts that can be used to enumerate objects and
grant specific privileges...

    http://pgedit.com/public/sql/acl_admin/index.html
    http://unf.be/postgresql/postgres_grant_all.perl
    http://www.archonet.com/pgdocs/grant-all.html

in general, DATABASE privileges relate to connecting to that database,
and having the rights to create schemas in that database.

SCHEMA privileges grant the rights to connect to a schema, and
create/modify schemas

table/view/etc privileges grant the rights to select/insert/update/etc
the mentioned tables.

see http://www.postgresql.org/docs/current/static/sql-grant.html for
more specifics.

В списке pgsql-general по дате отправления:

Предыдущее
От: "A.M."
Дата:
Сообщение: Re: nulls
Следующее
От: Tom Lane
Дата:
Сообщение: Re: pg_standby error - can't find 00000001.history