From: | Travis Whitton <whitton(at)atlantic(dot)net> |
---|---|
To: | pgsql-admin(at)postgresql(dot)org |
Subject: | Grant Question |
Date: | 2003-05-12 21:11:47 |
Message-ID: | slrnbc045f.42h.whitton@grub.ath.cx |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-admin |
Hi - I'm new to postgreSQL, and I'm having some issues with using GRANT.
I'm looking for a way to grant privileges on all tables in a given database
to a user. I can accomplish this using individual grant statements for each
table; however, a global grant is not working for me. Here's an example.
template1=# CREATE DATABASE dummy;
CREATE DATABASE
edit=# \c dummy;
You are now connected to database dummy.
dummy=# CREATE TABLE test (id int);
CREATE TABLE
dummy=# CREATE TABLE test2 (id int);
CREATE TABLE
dummy=# GRANT ALL ON DATABASE dummy TO devel;
GRANT
dummy=# \dp
Access privileges for database "dummy"
Schema | Table | Access privileges
--------+-------+-------------------
public | test |
public | test2 |
(2 rows)
No privileges...
dummy=# GRANT ALL ON test TO devel;
GRANT
dummy=# \dp
Access privileges for database "dummy"
Schema | Table | Access privileges
--------+-------+------------------------------------
public | test | {=,postgres=arwdRxt,devel=arwdRxt}
public | test2 |
(2 rows)
This works but only by referencing a specific table. Any
help would be appreciated.
Thanks,
Travis Whitton <whitton(at)atlantic(dot)net>
From | Date | Subject | |
---|---|---|---|
Next Message | timeless postgres | 2003-05-12 23:02:42 | Re: No flamefest please, MySQL vs. PostgreSQL AGAIN |
Previous Message | David F. Skoll | 2003-05-12 20:08:25 | Re: No flamefest please, MySQL vs. PostgreSQL AGAIN |