From: | Decibel! <decibel(at)decibel(dot)org> |
---|---|
To: | Kirill Simonov <xi(at)gamma(dot)dn(dot)ua> |
Cc: | pgsql-bugs(at)postgresql(dot)org |
Subject: | Re: BUG #3499: no owner privileges in information_schema.table_privileges |
Date: | 2007-08-04 16:53:46 |
Message-ID: | 20070804165346.GK25704@nasby.net |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-bugs |
Any idea what the spec says about this?
On Mon, Jul 30, 2007 at 10:28:37PM +0000, Kirill Simonov wrote:
>
> The following bug has been logged online:
>
> Bug reference: 3499
> Logged by: Kirill Simonov
> Email address: xi(at)gamma(dot)dn(dot)ua
> PostgreSQL version: 8.2.4
> Operating system: Linux
> Description: no owner privileges in
> information_schema.table_privileges
> Details:
>
> Owner privileges are not listed in the output of the
> information_schema.table_privileges view when no privileges are granted to
> other users. However if at least one GRANT statement was applied to a
> table, the table owner appears in the "table_privileges".
>
> The following example illustrates the problem:
>
>
> -- initialize the test environment: create two users: test_owner and
> test_user and create a table test_table, which owner is test_owner.
> # create user test_owner;
> # create user test_user;
> # create table test_table ();
> # alter table test_table owner to test_owner;
>
> -- table_privileges contains no rows for 'test_tables'
> # select grantee, privilege_type from information_schema.table_privileges
> where table_name = 'test_table';
> (0 rows)
>
> -- add a privilege for some other user.
> # grant select on test_table to test_user;
>
> -- suddenly, not only the test_user privileges appear in "table_privileges",
> but the "test_owner" privileges appear as well.
> # select grantee, privilege_type from information_schema.table_privileges
> where table_name = 'test_table';
> grantee | privilege_type
> ------------+----------------
> test_owner | SELECT
> test_owner | DELETE
> test_owner | INSERT
> test_owner | UPDATE
> test_owner | REFERENCES
> test_owner | TRIGGER
> test_user | SELECT
> (7 rows)
>
> -- drop test_*.
> # drop table test_table;
> # drop user test_user;
> # drop user test_owner;
>
> ---------------------------(end of broadcast)---------------------------
> TIP 2: Don't 'kill -9' the postmaster
>
--
Decibel!, aka Jim Nasby decibel(at)decibel(dot)org
EnterpriseDB http://enterprisedb.com 512.569.9461 (cell)
From | Date | Subject | |
---|---|---|---|
Next Message | Decibel! | 2007-08-04 17:01:15 | Re: Oddities with ANYARRAY |
Previous Message | Tom Lane | 2007-08-04 15:28:28 | Re: BUG #3511: timeofday()::timestamp failing on Saturday when using australian_timezones = on |