Re: Can I make direct calls to PostgreSQL server?

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: Can I make direct calls to PostgreSQL server?
Дата
Msg-id 9871.984610001@sss.pgh.pa.us
обсуждение исходный текст
Ответ на Can I make direct calls to PostgreSQL server?  (Roy Souther <roy@silicontao.com>)
Список pgsql-general
Roy Souther <roy@silicontao.com> writes:
> Can I make direct calls to PostgreSQL server? I have a lot of data to post to
> the local PostgreSQL server. I am wondering if I can connect directly to it
> to post data so I can by pass the extra layers of
> command -> SQL text string -> port -> SQL interpreter -> internal DB command
> I would like to go
> command -> lib function call  -> internal DB command

You could issue a COPY FROM STDIN command and then send your data in
COPY format.  This assumes that you are setting all the columns
explicitly (COPY doesn't supply defaults for omitted columns, the way
INSERT can) but it saves an awful lot of overhead.

            regards, tom lane

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

Предыдущее
От: Alexander Jerusalem
Дата:
Сообщение: LIKE and indexes?
Следующее
От: Richard H
Дата:
Сообщение: Re: [Q] post-crash behaviour