Alvaro Herrera wrote: > .. and here's the patch. I forgot an example involving the funniest of all object classes: default ACLs. Here it is.
alvherre=# create role rol1; CREATE ROLE alvherre=# create role rol2; CREATE ROLE alvherre=# create schema rol1 authorization rol1; CREATE SCHEMA alvherre=# alter default privileges for role rol1, rol2 grant insert on tables to alvherre; ALTER DEFAULT PRIVILEGES alvherre=# alter default privileges for role rol1 in schema rol1 grant insert on tables to alvherre; ALTER DEFAULT PRIVILEGES alvherre=# select oid,foo.* from pg_default_acl, lateral (select * from pg_identify_object(tableoid, oid, 0)) foo ; oid | type | schema | name | identity -------+-------------+--------+------+------------------------------------- 48839 | default acl | | | for role rol1 on tables 48840 | default acl | | | for role rol2 on tables 48844 | default acl | | | for role rol1 in schema rol1 on tables (4 filas) -- Álvaro Herrera http://www.2ndQuadrant.com/ PostgreSQL Development, 24x7 Support, Training & Services -- Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-hackers