Re: Proposal: knowing detail of config files via SQL

Поиск
Список
Период
Сортировка
От David Johnston
Тема Re: Proposal: knowing detail of config files via SQL
Дата
Msg-id CAKFQuwbyPX+fi8+MaXazQ-c0YxuaL5ZcivvTMdfQNJeabBvphQ@mail.gmail.com
обсуждение исходный текст
Ответ на Re: Proposal: knowing detail of config files via SQL  (David Fetter <david@fetter.org>)
Ответы Re: Proposal: knowing detail of config files via SQL  (Tom Lane <tgl@sss.pgh.pa.us>)
Список pgsql-hackers
On Fri, Jan 30, 2015 at 12:05 PM, David Fetter <david@fetter.org> wrote:
On Sat, Jan 31, 2015 at 12:50:20AM +0900, Sawada Masahiko wrote:

> [postgres][5432](1)=# select * from pg_file_settings where name = 'work_mem';
> -[ RECORD 1 ]------------------------------------------------------
> name       | work_mem
> setting    | 128MB
> sourcefile | /home/masahiko/pgsql/master/3data/hoge.conf
> -[ RECORD 2 ]------------------------------------------------------
> name       | work_mem
> setting    | 64MB
> sourcefile | /home/masahiko/pgsql/master/3data/postgresql.auto.conf

Masuhiko-san,

I apologize for not communicating clearly.  My alternative proposal is
to add a NULL-able sourcefile column to pg_settings.  This is as an
alternative to creating a new pg_file_settings view.

Why might the contents of pg_settings be different from what would be
in pg_file_settings, apart from the existence of this column?


​The contents of pg_settings uses the setting name as a primary key.

The contents of pg_file_setting uses a compound key consisting of the setting name and the source file.

See "work_mem" in the provided example.

More specifically pg_settings only care about the "currently active setting" while this cares about "inactive" settings as well.

David J.
 

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

Предыдущее
От: David Fetter
Дата:
Сообщение: Re: Proposal: knowing detail of config files via SQL
Следующее
От: Tom Lane
Дата:
Сообщение: Re: Proposal: knowing detail of config files via SQL