Using SELECT inside a COPY transaction with PHP - Mailing list pgsql-general

From Robert Fitzpatrick
Subject Using SELECT inside a COPY transaction with PHP
Date
Msg-id 1090417731.23933.19.camel@columbus.webtent.org
Whole thread Raw
Responses Re: Using SELECT inside a COPY transaction with PHP  (Tom Lane <tgl@sss.pgh.pa.us>)
List pgsql-general
I tried posting this to PHP-DB list, but no answers since yesterday. I'm
thinking it is not possible, but just trying to confirm. I am using
pg_exec($dbh, "COPY sometable FROM stdin USING DELIMITERS"). Once this
the connectino is made and this line has been issued, my script begins
analyzing each line of the CSV file and needs to do a SELECT statement
using some of the fields in the line to find other related data before
calling pg_end_copy($dbh), which syncs the data. Can another pg_exec
call be made for a SELECT statement before the COPY is over? My script
seems to hang at the point of the first SELECT.

--
Robert


pgsql-general by date:

Previous
From: "Dylan Milks"
Date:
Subject: Re: Insert images through ASP
Next
From:
Date:
Subject: Locking with foreign key constraints