Re: Performance penalty for remote access of postgresql (8.1.3)? any experiance?

From: Florian Weimer <fweimer(at)bfk(dot)de>
To: <guoping(dot)zhang(at)nec(dot)com(dot)au>
Cc: <pgsql-performance(at)postgresql(dot)org>
Subject: Re: Performance penalty for remote access of postgresql (8.1.3)? any experiance?
Date: 2006-07-19 07:38:10
Message-ID: 828xmq2gf1.fsf@mid.bfk.de
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-performance

* Guoping Zhang:

> Thanks for pointing me the cause, but we simply cannot use the COPY FROM
> solution.

Why not? Just do something like this:

CREATE TEMPORARY TABLE tmp (col1 TEXT NOT NULL, col2 INTEGER NOT NULL);
COPY tmp FROM STDIN;
row1 1
row2 2
...
\.
INSERT INTO target SELECT * FROM tmp;

If you need some kind of SELECT/INSERT/UPDATE cycle, it's far more
complex, of course, and I'm not quite happy with what I'm using right
now.

--
Florian Weimer <fweimer(at)bfk(dot)de>
BFK edv-consulting GmbH http://www.bfk.de/
Durlacher Allee 47 tel: +49-721-96201-1
D-76131 Karlsruhe fax: +49-721-96201-99

In response to

Browse pgsql-performance by date

  From Date Subject
Next Message Stephen Frost 2006-07-19 14:01:35 Re: Performance penalty for remote access of postgresql (8.1.3)? any experiance?
Previous Message Guoping Zhang 2006-07-19 07:33:34 Re: Performance penalty for remote access of postgresql (8.1.3)? any experiance?