From: | Alvaro Herrera <alvherre(at)2ndquadrant(dot)com> |
---|---|
To: | David G Johnston <david(dot)g(dot)johnston(at)gmail(dot)com> |
Cc: | pgsql-hackers(at)postgresql(dot)org |
Subject: | Re: Append to a GUC parameter ? |
Date: | 2014-08-06 01:25:13 |
Message-ID: | 20140806012513.GE9388@eldon.alvh.no-ip.org |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
David G Johnston wrote:
> Alvaro Herrera-9 wrote
> > I think this merits a new GUC flag, say GUC_LIST_ADDITIVE.
>
> Would that allow, without any special syntax, multiple declarations of, say,
> shared_preload_libraries, to have their values appended instead of the most
> (or least, I forget which) recent one overwrite (or be ignored by) the
> existing value?
>
> The idea of requiring "+=" instead of just "=" is not particularly
> appealing...
I'm not sold on += as the syntax to use. It just needs to be something
different from =. But I am thinking that whatever it is, it would be
required. Otherwise, for example if you have search_path=foo in
postgresql.conf and search_path=bar in auto.conf via ALTER SYSTEM, you
would end up with search_path=foo,bar instead of just bar which I think
would be the expected outcome. Of course, we would offer a new ALTER
SYSTEM option to indicate that you want to have auto.conf use += instead
of =.
The idea behing GUC_LIST_ADDITIVE is that += is only supported for
variables that have that flag set. If you tried to use += with other
variables, an error would be raised.
--
Álvaro Herrera http://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Training & Services
From | Date | Subject | |
---|---|---|---|
Next Message | Claudio Freire | 2014-08-06 01:30:42 | Re: Proposal: Incremental Backup |
Previous Message | Tom Lane | 2014-08-06 01:22:13 | Re: Append to a GUC parameter ? |