From: | Martijn van Oosterhout <kleptog(at)svana(dot)org> |
---|---|
To: | ohp(at)pyrenet(dot)fr |
Cc: | pgsql-hackers list <pgsql-hackers(at)postgresql(dot)org> |
Subject: | Re: where is the output |
Date: | 2005-12-21 18:32:35 |
Message-ID: | 20051221183228.GA2013@svana.org |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
On Wed, Dec 21, 2005 at 07:16:28PM +0100, ohp(at)pyrenet(dot)fr wrote:
> In PHP (Apache Module)
>
> I try pg_exec("COPY blah TO STDOUT WITH blah");
> It runs for ever...
>
> How can I get the output of COPY in PHP?
You need to use the API functions for copy. In C they are:
PQgetCopyData
PQputCopyData
PQputCopyEnd
I'm sure PHP has these functions, or perhaps the older versions:
PQgetline
PQputline
PQendcopy
Have a nice day,
--
Martijn van Oosterhout <kleptog(at)svana(dot)org> http://svana.org/kleptog/
> Patent. n. Genius is 5% inspiration and 95% perspiration. A patent is a
> tool for doing 5% of the work and then sitting around waiting for someone
> else to do the other 95% so you can sue them.
From | Date | Subject | |
---|---|---|---|
Next Message | Tom Lane | 2005-12-21 19:04:42 | Re: replicating tsearch2 across versions of postgres |
Previous Message | ohp | 2005-12-21 18:16:28 | where is the output |