I try to revoke create privileges (PG8.2.4) on the default tablespace and I
found following strange behavior:
----------------
As superuser:
revoke create on TABLESPACE pg_default from u_test1;
As u_test1:
ns_test=> create table test_06 (id int) tablespace pg_default;
ERROR: permission denied for tablespace pg_default
ns_test=> create table test_06 (id int);
CREATE TABLE
ns_test=> select relname, reltablespace from pg_class where relname like
'%test_06%';
relname | reltablespace
--------------+---------------
test_06 | 0
ns_test=# select oid,spcname from pg_tablespace;
oid | spcname
-------+------------
1664 | pg_global
24585 | ts_test
1663 | pg_default
------------------
It seems that we not able to revoke create privilege on default tablespace.
I think the main problem is that pg_default has OID=1663, but all objects in
this tablespace have reltablespace=0. Is there reason why 0 is used instead of
correct oid?
Zdenek
---------------------------(end of broadcast)---------------------------
TIP 2: Don't 'kill -9' the postmaster