Re: BUG #2085: pg_dump incompletely dumps ACLs - Mailing list pgsql-bugs

From Tom Lane
Subject Re: BUG #2085: pg_dump incompletely dumps ACLs
Date
Msg-id 3140.1133539430@sss.pgh.pa.us
Whole thread Raw
In response to Re: BUG #2085: pg_dump incompletely dumps ACLs  (David J N Begley <d.begley@uws.edu.au>)
Responses Re: BUG #2085: pg_dump incompletely dumps ACLs
List pgsql-bugs
David J N Begley <d.begley@uws.edu.au> writes:
> Earlier today, Tom Lane wrote:
>> Please provide a concrete test case, not handwaving.

> C:\Program Files\PostgreSQL\8.1\bin>createdb concrete "Test Case"
> CREATE DATABASE
> COMMENT

> C:\Program Files\PostgreSQL\8.1\bin>psql -q concrete
> concrete=# REVOKE ALL ON DATABASE concrete FROM PUBLIC;
> concrete=# REVOKE ALL ON DATABASE concrete FROM david;
> concrete=# SELECT datacl FROM pg_database WHERE datname = 'concrete';
>  datacl
> --------
>  {}
> (1 row)

> concrete=# \q

> C:\Program Files\PostgreSQL\8.1\bin>pg_dump -C -f \windows\temp\dump.sql concrete

Database ACLs are dumped by pg_dumpall, not pg_dump.  I agree this is a
bit inconsistent considering that pg_dump has a -C option, but the -C
option has always been pretty poorly thought out :-(.

Given that -C overlaps pg_dumpall functionality anyway, maybe it should
dump GRANT/REVOKE commands for the database too?  Any thoughts pro or
con out there?

            regards, tom lane

pgsql-bugs by date:

Previous
From: Arjen van der Meijden
Date:
Subject: Re: BUG #2075: Strange choice of bitmap-index-scan
Next
From: Alvaro Herrera
Date:
Subject: Re: BUG #2085: pg_dump incompletely dumps ACLs