Re: [HACKERS] Performance testing of COPY (SELECT) TO

Поиск
Список
Период
Сортировка
От Alvaro Herrera
Тема Re: [HACKERS] Performance testing of COPY (SELECT) TO
Дата
Msg-id 20060828170013.GS27526@alvh.no-ip.org
обсуждение исходный текст
Ответ на Re: [HACKERS] Performance testing of COPY (SELECT) TO  (Zoltan Boszormenyi <zboszor@dunaweb.hu>)
Ответы Re: [HACKERS] Performance testing of COPY (SELECT) TO  (Zoltan Boszormenyi <zboszor@dunaweb.hu>)
Список pgsql-patches
Zoltan Boszormenyi wrote:
> Alvaro Herrera írta:

> But COPY view (col1, col2, ...) TO may still be
> useful even if the COPY (SELECT ...) (col1, col2, ...) TO
> is pointless. [1]

Hum, I don't understand what you're saying here -- are you saying that
you can't do something with the first form, that you cannot do with the
second?


> >It's ugly because you are forcing the system to parse something that
> >was already parsed.
>
> Well, to be true to the word, during parsing COPY view TO
> the parser never saw SELECT * FROM view.

Hmm!

The COPY view stuff stopped working when I changed back the "relation"
case.  Your patch changed it so that instead of flowing as RangeVar all
the way to the copy.c code, the parser changed it into a "select * from
%s" query, and then stashed the resulting Query node into the "query"
%case.  (So what was happening was that the Relation case was never
%used).  I reverted this.


> >On the other hand I don't see why you are arguing in favor of a useless
> >feature whose coding is dubious; you can have _the same thing_ with nice
> >code and no discussion.
>
> Because of [1] and because Mr. Schoenig's arguments
> about changing schemas.

Yeah, that argument makes sense to me as well.

--
Alvaro Herrera                                http://www.CommandPrompt.com/
PostgreSQL Replication, Consulting, Custom Development, 24x7 support

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

Предыдущее
От: Alvaro Herrera
Дата:
Сообщение: Re: [HACKERS] Performance testing of COPY (SELECT) TO
Следующее
От: Hans-Juergen Schoenig
Дата:
Сообщение: Re: [HACKERS] Performance testing of COPY (SELECT) TO