Re: IMPORT FOREIGN SCHEMA statement

Поиск
Список
Период
Сортировка
От Stephen Frost
Тема Re: IMPORT FOREIGN SCHEMA statement
Дата
Msg-id 20140527140031.GJ2556@tamriel.snowman.net
обсуждение исходный текст
Ответ на Re: IMPORT FOREIGN SCHEMA statement  (Ronan Dunklau <ronan.dunklau@dalibo.com>)
Список pgsql-hackers
* Ronan Dunklau (ronan.dunklau@dalibo.com) wrote:
> So, without extending the syntax too much, we could add options:
>
> IMPORT FOREIGN SCHEMA remote_schema FROM SERVER server_name INTO local_schema
> [ { LIMIT TO | EXCEPT } (table_name [, ...])]
> [ OPTIONS (option_list) ]
>
> This option list could then contain fdw-specific options, including type
> mapping.

Yup, that looks reasonable to me.

> Or we could add a specific clause:
>
> IMPORT FOREIGN SCHEMA remote_schema FROM SERVER server_name INTO local_schema
> [ { LIMIT TO | EXCEPT } (table_name [, ...])]
> [ OPTIONS (option_list) ]
> [ TYPE MAPPING some mapping_definition ]

-1 on this one.

> With mapping_definition being either a tuple, or well-defined jsonb format
> common accross FDWs.
>
> A third solution, which I don't like but doesn't modify the SQL grammar, would
> be to encode the options in the remote_schema name.

Yeah, don't like that one either.
Thanks,
    Stephen

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

Предыдущее
От: Stephen Frost
Дата:
Сообщение: Re: IMPORT FOREIGN SCHEMA statement
Следующее
От: Petr Jelinek
Дата:
Сообщение: Re: IMPORT FOREIGN SCHEMA statement