Re: ATSimpleRecursion() and inheritance foreign parents

Поиск
Список
Период
Сортировка
От Amit Langote
Тема Re: ATSimpleRecursion() and inheritance foreign parents
Дата
Msg-id CA+HiwqHQYHwT2tMshks1ZSWp7Vu+7ZU9L42xF4D-YwPAoBZigA@mail.gmail.com
обсуждение исходный текст
Ответ на Re: ATSimpleRecursion() and inheritance foreign parents  (David Fetter <david@fetter.org>)
Ответы Re: ATSimpleRecursion() and inheritance foreign parents  (David Fetter <david@fetter.org>)
Список pgsql-hackers
On Tue, Apr 28, 2015 at 9:28 PM, David Fetter <david@fetter.org> wrote:
> On Tue, Apr 28, 2015 at 03:17:08PM +0900, Amit Langote wrote:
>>
>> An example,
>> postgres=# alter foreign table fparent alter a type char;
>> ALTER FOREIGN TABLE
>>
>> postgres=# select * from fparent;
>> ERROR:  attribute "a" of relation "fchild1" does not match parent's type
>>
>> Above error, AIUI, is hit much before it is determined that fparent is a
>> foreign table, whereas the following is FDW-specific (waiting to happen) error,
>>
>> postgres=# alter foreign table fparent add b char;
>> ALTER FOREIGN TABLE
>>
>> postgres=# SELECT * FROM fparent;
>> ERROR:  column "b" does not exist
>> CONTEXT:  Remote SQL command: SELECT a, b FROM public.parent
>
> I'm pretty sure this is a bug.  The way I see it, foreign tables can
> either fully participate in table inheritance, or not at all, because
> any inconsistencies here will cause confusion at best.
>

As mentioned by Fujita-san, the first one is definitely a bug (he sent
a patch) but the second one is not quite related to inheritance; that
is, it can happen irrespective of foreign tables participating in
inheritance and is documented.

Thanks,
Amit



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

Предыдущее
От: Robert Haas
Дата:
Сообщение: Re: Can pg_dump make use of CURRENT/SESSION_USER
Следующее
От: David Fetter
Дата:
Сообщение: Re: ATSimpleRecursion() and inheritance foreign parents