Re: Create a Foreign Table for PostgreSQL CSV Logs

Поиск
Список
Период
Сортировка
От David G. Johnston
Тема Re: Create a Foreign Table for PostgreSQL CSV Logs
Дата
Msg-id CAKFQuwY=pgJLDfcmy6T0_mjL0RGcZQFFALKM=_q9YkfAhmiVcA@mail.gmail.com
обсуждение исходный текст
Ответ на Re: Create a Foreign Table for PostgreSQL CSV Logs  (Олег Самойлов <splarv@ya.ru>)
Ответы Re: Create a Foreign Table for PostgreSQL CSV Logs  (Bruce Momjian <bruce@momjian.us>)
Список pgsql-docs
On Mon, Aug 24, 2020 at 6:17 AM Олег Самойлов <splarv@ya.ru> wrote:
There must not be constraints at all. Constraints are needed to check incoming data to the table. But here table is read-only for database!

Please don't top-post.


So all your constraints is totally useless.
> > could become:
> >
> > connection_from text check(connection_from ~ '^[^:]+:[0-9]+$) -- the host and
> > port of the client, colon-separated

I'll agree that the benefit for adding the constraints to a foreign table are less than for a normal table but it is still not zero.  Constraints are also a form of documentation.  And also can be used (at least non-null ones) during optimization.

David J.

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

Предыдущее
От: Bruce Momjian
Дата:
Сообщение: Re: Document "59.2. Built-in Operator Classes" have a clerical error?
Следующее
От: Bruce Momjian
Дата:
Сообщение: Re: Procedures