On 7/1/06, Garcia, Joshua <Joshua.Garcia@xerox.com> wrote:
>> PQexec(conn, "CREATE TABLE foo (a int4, b char(16), d double
>> precision)");
>> PQexec(conn, "COPY foo FROM STDIN DELIMITER AS '|'");
>> foreach ($my_results as &$value) {
>> PQputline(conn, $value);
>> }
>> PQputline(conn,"\\.\n");
>> PQendcopy(conn);
> Is there a way to do that without using deprecated libpq copy functions?
Ummm ... copy in that example is an SQL function.
http://www.postgresql.org/docs/8.1/interactive/sql-copy.html
Unless of course the PHP guys have made any of the sql statements
an implementation of libpq (in which case the answer to your
question would be no).
> Thanks,
> Josh
Cheers,
Andrej