Re: set_config() documentation clarification

Поиск
Список
Период
Сортировка
От Pavel Stehule
Тема Re: set_config() documentation clarification
Дата
Msg-id CAFj8pRA31PmczgvkoeAJzXzOf1-hkH=fdZYD4vGc4PfvoNGL2A@mail.gmail.com
обсуждение исходный текст
Ответ на Re: set_config() documentation clarification  (Bruce Momjian <bruce@momjian.us>)
Ответы Re: set_config() documentation clarification  ("Joel Jacobson" <joel@compiler.org>)
Список pgsql-hackers


út 5. 1. 2021 v 18:51 odesílatel Bruce Momjian <bruce@momjian.us> napsal:
On Mon, Jan  4, 2021 at 09:46:32AM -0700, David G. Johnston wrote:
> On Mon, Jan 4, 2021 at 8:26 AM Joel Jacobson <joel@compiler.org> wrote:
>
>     In the documentation at https://www.postgresql.org/docs/current/
>     functions-admin.html
>     this behaviour is not mentioned anywhere as far as I can see:
>
>
>
> https://www.postgresql.org/docs/current/runtime-config-custom.html
>
> I do think "Customized Options" is an accurate description.  One needs to
> consider their usage of such variables as "modular" even though there is no
> library code involved.  i.e., the description is possibly overly specific but
> the variables created in this manner are simply namespaced but otherwise usable
> in any manner you deem fit.

I think I tried to make this feature more visible a few years ago and
some people said we might remove it someday, so don't do that.  If that
is false, I think we can make it more prominent.

This feature is frequently used as a workaround for missing global package variables. And a lot of scripts use this feature as only one possibility to push parameters to the DO statement.

Unfortunately - there is not any guard against typo errors, are untyped, and access is slow - it is designed for different purposes.

Schema variables are designed specially for described purposes https://commitfest.postgresql.org/31/1608/.

Regards

Pavel



--
  Bruce Momjian  <bruce@momjian.us>        https://momjian.us
  EnterpriseDB                             https://enterprisedb.com

  The usefulness of a cup is in its emptiness, Bruce Lee



В списке pgsql-hackers по дате отправления:

Предыдущее
От: Bruce Momjian
Дата:
Сообщение: Re: Context diffs
Следующее
От: Fujii Masao
Дата:
Сообщение: Re: recovery_target_timeline & documentation