Re: Performance testing of COPY (SELECT) TO

From: Bruce Momjian <bruce(at)momjian(dot)us>
To: Böszörményi Zoltán <zboszor(at)dunaweb(dot)hu>
Cc: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, pgsql-hackers(at)postgresql(dot)org, pgsql-patches(at)postgresql(dot)org
Subject: Re: Performance testing of COPY (SELECT) TO
Date: 2006-08-26 17:00:47
Message-ID: 200608261700.k7QH0lP13760@momjian.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers pgsql-patches


Your patch has been added to the PostgreSQL unapplied patches list at:

http://momjian.postgresql.org/cgi-bin/pgpatches

It will be applied as soon as one of the PostgreSQL committers reviews
and approves it.

---------------------------------------------------------------------------

Bszrmnyi Zoltn wrote:
> > B?sz?rm?nyi Zolt?n <zboszor(at)dunaweb(dot)hu> writes:
> >> With PostgreSQL 8.1.4, I used this:
> >
> >> begin;
> >> select ... into temp myquery1;
> >> copy myquery1 to stdout csv delimiter '|';
> >> rollback;
> >
> > The performance of this would doubtless vary a lot with the temp_buffers
> > setting. Did you try different values?
>
> Yes, I did, but now checked back with 8.2CVS.
> The previously quoted result was achieved with
> temp_buffers = 1000 on both 8.1.4 and 8.2CVS.
> On 8.2CVS with temp_buffers = 4096, the 10 client case kills
> the machine with swapping, but the 3 client runtime with
> COPY(SELECT) went down to 2:41. The SELECT INTO TEMP
> case went down to 3:36.
>
> > It'd also be interesting to time the same way (with a temp table) in
> > devel. I don't remember whether we did any performance work on the
> > COPY CSV data path in this cycle, or whether that was all present in
> > 8.1. In any case it'd be worth proving that the COPY SELECT patch isn't
> > degrading performance of the copy-a-relation case.
>
> I will report back with that, say on Monday.
>
> In the meantime, I documented the COPY (SELECT) case
> and modified parser/analyze.c and tcop/utility.c so neither of them
> calls anything from under another directory. I think it's cleaner now.
> Also, I tried to implement more closely what printtup() does.
> Please, review.
>
> Best regards,
> Zolt?n B?sz?rm?nyi

[ Attachment, skipping... ]

>
> ---------------------------(end of broadcast)---------------------------
> TIP 2: Don't 'kill -9' the postmaster

--
Bruce Momjian bruce(at)momjian(dot)us
EnterpriseDB http://www.enterprisedb.com

+ If your life is a hard drive, Christ can be your backup. +

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message David Fetter 2006-08-26 17:14:33 Re: [HACKERS] New XML section for documentation
Previous Message Bruce Momjian 2006-08-26 16:54:39 Re: Coding style for emacs

Browse pgsql-patches by date

  From Date Subject
Next Message Joshua D. Drake 2006-08-26 17:21:49 Re: Adding fulldisjunctions to the contrib
Previous Message Bruce Momjian 2006-08-26 16:54:39 Re: Coding style for emacs