Re: Can pg_dump make use of CURRENT/SESSION_USER - Mailing list pgsql-hackers

From Fabrízio de Royes Mello
Subject Re: Can pg_dump make use of CURRENT/SESSION_USER
Date
Msg-id CAFcNs+p6iq0US8pyx2nTv_+ooFzssRT700N6icqk966O+sSmaQ@mail.gmail.com
Whole thread Raw
In response to Re: Can pg_dump make use of CURRENT/SESSION_USER  (Robert Haas <robertmhaas@gmail.com>)
Responses Re: Can pg_dump make use of CURRENT/SESSION_USER
List pgsql-hackers

On Wed, Mar 18, 2015 at 1:24 PM, Robert Haas <robertmhaas@gmail.com> wrote:
>
> On Tue, Mar 17, 2015 at 1:24 PM, Alvaro Herrera
> <alvherre@2ndquadrant.com> wrote:
> > If we ever implement something like
> >
> > COMMENT ON CURRENT_DATABASE IS ...
> >
> > it will be useful, because you will be able to restore a dump into
> > another database and have the comment apply to the target database.

I think it's simple to implement, but how about pg_dump... we need to add new option (like --use-current-database) or am I missing something ?


> > (Also, I wonder about
> > ALTER USER foo IN DATABASE current_database ...
> > because that will let us dump per-database user options too.)
>
> +1 for both of those ideas.
>

Can you explain more about this idea?

Regards,

--
Fabrízio de Royes Mello
Consultoria/Coaching PostgreSQL
>> Timbira: http://www.timbira.com.br
>> Blog: http://fabriziomello.github.io
>> Linkedin: http://br.linkedin.com/in/fabriziomello
>> Twitter: http://twitter.com/fabriziomello
>> Github: http://github.com/fabriziomello

pgsql-hackers by date:

Previous
From: Robert Haas
Date:
Subject: Re: Rethinking the parameter access hooks for plpgsql's benefit
Next
From: Robert Haas
Date:
Subject: Re: Can pg_dump make use of CURRENT/SESSION_USER