GRANT permissions on views have no effect; \dv reports nothing

From: pgsql-bugs(at)postgresql(dot)org
To: pgsql-bugs(at)postgresql(dot)org
Subject: GRANT permissions on views have no effect; \dv reports nothing
Date: 2001-05-16 00:47:03
Message-ID: 200105160047.f4G0l3Q56397@hub.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-bugs

Kristis Makris (kristis dot makris at datasoft dot com) reports a bug with a severity of 1
The lower the number the more severe it is.

Short Description
GRANT permissions on views have no effect; \dv reports nothing

Long Description
I run a bunch if GRANT statements on tables/views/sequences. The permissions set on teh tables/sequences go in effect correctly. All the grant permissions performed on the views have no effect.

Doing a "\dp" within the pgsql tool does not even list the views, while the permissions on the tables/sequences are listed, even if there aren't any.

Also, doing a "\dv" within the pgsql tool does not list any views at all; it reports: "No relations found."

The views are not listed as relations anywhere, yet they are executed properly

Sample Code
perms=# create view test AS SELECT 'hi'::text AS RESULT;
CREATE
perms=# \dv
No relations found.
perms=# select * from test;
result
--------
hi
(1 row)

perms=# \dp
Access permissions for database "perms"
Relation | Access permissions
----------+--------------------
(0 rows)

perms=# grant all ON test TO public;
CHANGE
perms=# \dp
Access permissions for database "perms"
Relation | Access permissions
----------+--------------------
(0 rows)

perms=# \dv
No relations found.
perms=# create table testtable(id int4);
CREATE
perms=# \dp
Access permissions for database "perms"
Relation | Access permissions
-----------+--------------------
testtable |
(1 row)

perms=# grant all on testtable to public;
CHANGE
perms=# \dp
Access permissions for database "perms"
Relation | Access permissions
-----------+---------------------------
testtable | {"=arwR","postgres=arwR"}
(1 row)

perms=# grant all ON test TO public;
CHANGE
perms=# \dp
Access permissions for database "perms"
Relation | Access permissions
-----------+---------------------------
testtable | {"=arwR","postgres=arwR"}
(1 row)

No file was uploaded with this report

Responses

Browse pgsql-bugs by date

  From Date Subject
Next Message Tom Lane 2001-05-16 04:22:45 Re: GRANT permissions on views have no effect; \dv reports nothing
Previous Message Alex 2001-05-15 18:52:26 timestamp being timestamp with time zone