Received: from localhost (unknown [200.46.208.211]) by mail.postgresql.org (Postfix) with ESMTP id BBA68633FE7 for ; Sun, 30 Aug 2009 12:56:41 -0300 (ADT) Received: from mail.postgresql.org ([200.46.204.86]) by localhost (mx1.hub.org [200.46.208.211]) (amavisd-maia, port 10024) with ESMTP id 27256-07 for ; Sun, 30 Aug 2009 15:56:30 +0000 (UTC) X-Greylist: domain auto-whitelisted by SQLgrey-1.7.6 Received: from mail-yw0-f186.google.com (mail-yw0-f186.google.com [209.85.211.186]) by mail.postgresql.org (Postfix) with ESMTP id 03031633FD5 for ; Sun, 30 Aug 2009 12:56:30 -0300 (ADT) Received: by ywh16 with SMTP id 16so3482611ywh.19 for ; Sun, 30 Aug 2009 08:56:30 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:received:in-reply-to:references :date:message-id:subject:from:to:cc:content-type :content-transfer-encoding; bh=ru8FHhiCj1qCOGIsDg8A+HYZ2JhLj4SIwt0OMnbJ4xM=; b=WEHoED0jdBCjMWAPQtL0/gbMphhY2zbAXliRKI3O3914zqRc6xVlsPBnvLO7chuXr8 L+8Cc7OuEPKigKTz/10XESFGrT11YHoQ27erf+orFhystNCGi34UnLlBKWp9EDncuR92 Keu9A9ewhKJDEj8Ds+xOg8yWjq7X4P8ORSLBM= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type:content-transfer-encoding; b=C+HsMiSKilPi7qkJLT7FnL0RWzOqLIr+XPiG4fT0qYKJNorD9rDJE5QgpWYZVaObeR D3NlnXf5n+7smbls3LTVbugpqgc032HMKD88Udo7+J/6BBxgjSnmykJJcobN9ALkNVBv /B/4GBtMpzr4LGV932wbTeYtgER0yf18I+plQ= MIME-Version: 1.0 Received: by 10.150.26.5 with SMTP id 5mr6935069ybz.228.1251647789785; Sun, 30 Aug 2009 08:56:29 -0700 (PDT) In-Reply-To: <13182.1251647634@sss.pgh.pa.us> References: <797097.88507.qm@web76214.mail.sg1.yahoo.com> <162867790908292351g14087219r970576b9006fb91b@mail.gmail.com> <13182.1251647634@sss.pgh.pa.us> Date: Sun, 30 Aug 2009 17:56:29 +0200 Message-ID: <162867790908300856u1eb20f66sfeec34a52ab6db03@mail.gmail.com> Subject: Re: NEED HELP COPY TO DYNAMIC OUTPUT FILE From: Pavel Stehule To: Tom Lane Cc: Yogi Rizkiadi , pgsql-sql@postgresql.org Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable X-Virus-Scanned: Maia Mailguard 1.0.1 X-Spam-Status: No, hits=-2.526 tagged_above=-10 required=5 tests=AWL=0.073, BAYES_00=-2.599 X-Spam-Level: X-Archive-Number: 200908/153 X-Sequence-Number: 33062 2009/8/30 Tom Lane : > Pavel Stehule writes: >> COPY in plpgsql are not allowed. > > I think it will work if you use an EXECUTE. > > =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2= =A0 =C2=A0regards, tom lane > I didn't test it. regards Pavel Stehule