"Re: Question about grant create on database and pg_dump/pg_dumpall

From: Rafia Sabih <rafia(dot)sabih(at)enterprisedb(dot)com>
To: Haribabu Kommi <kommi(dot)haribabu(at)gmail(dot)com>, pgsql-hackers(at)postgresql(dot)org
Subject: "Re: Question about grant create on database and pg_dump/pg_dumpall
Date: 2016-09-26 04:29:09
Message-ID: CAOGQiiMYq=HNrL5X_DB2+EwdZG-hwy_93TyXoeQD9rCSACYQQQ@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Tue, Jul 5, 2016 at 06:39 AM, Haribabu Kommi
kommi(dot)haribabu(at)gmail(dot)com wrote:

Still i feel the GRANT statements should be present, as the create
database statement
is generated only with -C option. So attached patch produces the GRANT
statements based
on the -x option.

The attached patch does the job fine. However, I am a little skeptical
about this addition, since, it is clearly mentioned in the documentation of
pg_dump that it would not restore global objects, then why expecting this.
This addditon makes pg_dump -C somewhat special as now it is restoring
these grant statements. Only if we consider the popular method of
dump-restore mentioned in the thread (https://www.postgresql.org/me
ssage-id/E1VYMqi-0001P4-P4%40wrigleys.postgresql.org) with pg_dumpall -g
and then individual pg_dump, then it would be helpful to have this patch.

Regards,
Rafia Sabih
EnterpriseDB:: http://www.enterprisedb.com

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Thomas Munro 2016-09-26 04:46:48 Re: Tracking wait event for latches
Previous Message Thomas Munro 2016-09-26 04:12:50 Re: PoC: Make it possible to disallow WHERE-less UPDATE and DELETE