Re: pg_dumpall --exclude-database option

Поиск
Список
Период
Сортировка
От Andrew Dunstan
Тема Re: pg_dumpall --exclude-database option
Дата
Msg-id ed721552-42ce-8459-b1db-1e57bb44117f@2ndQuadrant.com
обсуждение исходный текст
Ответ на Re: pg_dumpall --exclude-database option  (Alvaro Herrera <alvherre@2ndquadrant.com>)
Ответы Re: pg_dumpall --exclude-database option  (Dmitry Dolgov <9erthalion6@gmail.com>)
Re: pg_dumpall --exclude-database option  (Andrew Dunstan <andrew.dunstan@2ndquadrant.com>)
Список pgsql-hackers
On 11/17/18 9:55 AM, Alvaro Herrera wrote:
> The comment in expand_dbname_patterns is ungrammatical and mentions
> "OID" rather than "name", so I suggest
>
>     /*
>      * The loop below might sometimes result in duplicate entries in the
>      * output name list, but we don't care.
>      */


Will fix.



> I'm not sure this is grammatical either:
>     exclude databases whose name matches PATTERN
> I would have written it like this:
>     exclude databases whose names match PATTERN
> but I'm not sure (each database has only one name, of course, but aren't
> you talking about multiple databases there?)



I think the original is grammatical.



> Other than that, the patch seems fine to me -- I tested and it works as
> intended.
>
> Personally I would say "See also expand_table_name_patterns" instead of
> "This is similar to code in pg_dump.c for handling matching table names.",
> as well as mention this function in expand_table_name_patterns' comment.
> (No need to mention expand_schema_name_patterns, since these are
> adjacent.)  But this is mostly stylistic and left to your own judgement.
>
> In the long run, I think we should add an option to processSQLNamePattern
> to use OR instead of AND, which would fix both this problem as well as
> pg_dump's.  I don't think that's important enough to stall this patch.


Thanks for the review.


cheers


andrew

-- 
Andrew Dunstan                https://www.2ndQuadrant.com
PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services



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

Предыдущее
От: Andrew Dunstan
Дата:
Сообщение: Re: _isnan() on Windows
Следующее
От: Fabien COELHO
Дата:
Сообщение: Re: doc - improve description of default privileges