Re: Add FOREIGN to ALTER TABLE in pg_dump

Поиск
Список
Период
Сортировка
От Alvaro Herrera
Тема Re: Add FOREIGN to ALTER TABLE in pg_dump
Дата
Msg-id 20190925200405.GA22045@alvherre.pgsql
обсуждение исходный текст
Ответ на Add FOREIGN to ALTER TABLE in pg_dump  (Luis Carril <luis.carril@swarm64.com>)
Ответы Re: Add FOREIGN to ALTER TABLE in pg_dump  (Luis Carril <luis.carril@swarm64.com>)
Список pgsql-hackers
On 2019-Jul-12, Luis Carril wrote:

> Hello,
>     pg_dump creates plain ALTER TABLE statements even if the table is a foreign table, which for someone reading the
dumpis confusing.
 
>     This also made a difference when applying the dump if there is any plugin installed that hooks on ProcessUtility,
becausethe plugin could react differently to ALTER TABLE than to ALTER FOREIGN TABLE.  Opinions?
 

I think such a hook would be bogus, because it would miss anything done
by a user manually.

I don't disagree with adding FOREIGN, though.

Your patch is failing the pg_dump TAP tests.  Please use
configure --enable-tap-tests, fix the problems, then resubmit.

>     An unrelated question: if I apply pgindent to a file (in this case pg_dump.c) and get a bunch of changes on the
indentationthat are not related to my patch, which is the accepted policy? A different patch first with only the
indentation? Maybe, am I using pgindent wrong?
 

We don't typically accept pgindent-only changes at random points in
the devel cycle.

I would suggest to run pgindent over the file and "git add -p" only the
changes that are relevant to your patch, discard the rest.
(Alternative: run pgindent, commit that, then apply your patch, pgindent
again and "git commit --amend", then "git rebase -i" and discard the
first pgindent commit.  Your patch ends up pgindent-correct without
disturbing the rest of the file/tree).

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



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

Предыдущее
От: Andres Freund
Дата:
Сообщение: Re: Don't codegen deform code for virtual tuples in expr eval forscan fetch
Следующее
От: Alvaro Herrera
Дата:
Сообщение: Re: [Patch] Add a reset_computed_values function inpg_stat_statements