Re: CREATE FOREIGN TABLE ( ... LIKE ... )

Поиск
Список
Период
Сортировка
От Michael Paquier
Тема Re: CREATE FOREIGN TABLE ( ... LIKE ... )
Дата
Msg-id CAB7nPqTmUo_3668uHJ8s=PFV=BS-PQN60n46yT8tuUoZxGjakw@mail.gmail.com
обсуждение исходный текст
Ответ на Re: CREATE FOREIGN TABLE ( ... LIKE ... )  (Andres Freund <andres@2ndquadrant.com>)
Ответы Re: CREATE FOREIGN TABLE ( ... LIKE ... )
Re: CREATE FOREIGN TABLE ( ... LIKE ... )
Список pgsql-hackers
On Tue, Feb 18, 2014 at 7:22 AM, Andres Freund <andres@2ndquadrant.com> wrote:
> On 2014-02-17 23:07:45 +0900, Michael Paquier wrote:
>> On Mon, Feb 17, 2014 at 6:28 PM, Andres Freund <andres@2ndquadrant.com> wrote:
>> > I don't think this really has gone above Needs Review yet.
>> I am not sure that this remark makes the review of this patch much
>> progressing :(
>>
>> By the way, I spent some time looking at it and here are some
>> comments:
>
> David just pinged me and tricked me into having a quick look :)
>
> Unless I miss something this possibly allows column definition to slip
> by that shouldn't because normally all fdw column definitions are passed
> through transformColumnDefinition() which does some checks, but the
> copied ones aren't.
> I haven't looked long enough to see whether that's currently
> problematic, but even if not, it's sure a trap waiting to spring.
transformColumnDefinition contains checks about serial and constraints
mainly. The only thing that could be problematic IMO is the process
done exclusively for foreign tables which is the creation of some
ALTER FOREIGN TABLE ALTER COLUMN commands when per-column options are
detected, something that is not passed to a like'd table with this
patch. This may meritate a comment in the code.
Actually after more thinking I think that it would make sense to have
another INCLUDING/EXCLUDING option for foreign tables: OPTIONS to pass
the column options when link is done from another foreign table. This
should be another patch though.
Regards,
-- 
Michael



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

Предыдущее
От: Bjorn Munch
Дата:
Сообщение: Re: Ctrl+C from sh can shut down daemonized PostgreSQL cluster
Следующее
От: Peter Geoghegan
Дата:
Сообщение: Re: Memory ordering issue in LWLockRelease, WakeupWaiters, WALInsertSlotRelease