X-Original-To: pgsql-general-postgresql.org@localhost.postgresql.org Received: from localhost (unknown [200.46.204.144]) by svr1.postgresql.org (Postfix) with ESMTP id E05C03A4075 for ; Mon, 8 Nov 2004 19:14:33 +0000 (GMT) Received: from svr1.postgresql.org ([200.46.204.71]) by localhost (av.hub.org [200.46.204.144]) (amavisd-new, port 10024) with ESMTP id 91849-03 for ; Mon, 8 Nov 2004 19:14:26 +0000 (GMT) Received: from smtp.lewczuk.com (118.224.149.195.tld.pl [195.149.224.118]) by svr1.postgresql.org (Postfix) with SMTP id 86CBB3A4038 for ; Mon, 8 Nov 2004 19:14:23 +0000 (GMT) Received: (qmail 13473 invoked by uid 700); 8 Nov 2004 19:14:18 -0000 Received: from nat-mo2.aster.pl (HELO ?10.71.11.58?) (marek@lewczuk.com@212.76.39.231) by 118.224.149.195.tld.pl with SMTP; 8 Nov 2004 19:14:18 -0000 Message-ID: <418FC58E.1000404@lewczuk.com> Date: Mon, 08 Nov 2004 20:14:22 +0100 From: Marek Lewczuk User-Agent: Mozilla Thunderbird 0.9 (Windows/20041103) X-Accept-Language: en-us, en MIME-Version: 1.0 To: Goutam Paruchuri Cc: Lista dyskusyjna pgsql-general , Lista dyskusyjna pgsql-sql Subject: Re: how to use COPY within plperl References: In-Reply-To: Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Virus-Scanned: by amavisd-new at hub.org X-Spam-Status: No, hits=0.0 tagged_above=0.0 required=5.0 tests= X-Spam-Level: X-Archive-Number: 200411/334 X-Sequence-Number: 68414 Goutam Paruchuri wrote: > Why can you not use simple insert statements (sql insert). > Copy is meant to transfer large amount of data from text files to > databases and vice versa. "Insert" is much slower if there are many (hundreds, thousands) data to be inserted - and in my case there will be thousands of inserts made by plperl. I can make a file with the data (and load using COPY), but it would be better to use copy from stdin. Thanks ML