Re: COPY Hacks (WAS: RE: Postgresql vs SQLserver for this application ?)

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: COPY Hacks (WAS: RE: Postgresql vs SQLserver for this application ?)
Дата
Msg-id 5831.1112819233@sss.pgh.pa.us
обсуждение исходный текст
Ответ на COPY Hacks (WAS: RE: Postgresql vs SQLserver for this application ?)  (Mischa <mischa.Sandberg@telus.net>)
Список pgsql-performance
Mischa <mischa.Sandberg@telus.net> writes:
> Using COPY ... FROM STDIN via the Perl DBI (DBD::Pg) interface,
> I accidentally strung together several \n-terminated input lines,
> and sent them to the server with a single "putline".

> To my (happy) surprise, I ended up with exactly that number of rows
> in the target table.

> Is this a bug?

No, it's the way it's supposed to work.  "putline" really just sends a
stream of data ... there's no semantic significance to the number of
putline calls you use to send the stream, only to the contents of the
stream.  (By the same token, it's unlikely that deliberately aggregating
such calls would be much of a win.)

            regards, tom lane

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

Предыдущее
От: "Dave Held"
Дата:
Сообщение: Re: COPY Hacks (WAS: RE: Postgresql vs SQLserver for this application ?)
Следующее
От: Tom Lane
Дата:
Сообщение: Re: Plan for relatively simple query seems to be very inefficient