[postgis-devel] [postgis-users] Changing transaction behaviour in shp2pgsql

Chris Hodgson chodgson at refractions.net
Mon Mar 15 09:52:02 PDT 2010


I think COPY has the same transactional behaviour as INSERT, except that 
with COPY you define a whole bunch of inserts in one statement. 
Regardless, using copy will not allow you to accept a single failed 
insert in the middle of other successful inserts, which was the original 
request.

Looking at trunk, I can't see where we are doing any chunking in the 
current code... Perhaps I am blind, but I can't see the condition  check 
nor the value for the number of inserts in a chunk. Looks like the 
loader uses one big transaction.

Chris

strk wrote:
> On Sun, Mar 14, 2010 at 03:41:25PM -0700, Chris Hodgson wrote:
>   
>> It's chunked because loading records individually is significantly 
>> slower, and doing one large transaction can easily run you out of 
>> memory/transaction space.
>>     
>
> What about the COPY interface ? Does it suffer of the same
> memory/transaction space limits ?
>
> --strk; 
>
>   ()   Free GIS & Flash consultant/developer
>   /\   http://strk.keybit.net/services.html
> _______________________________________________
> postgis-devel mailing list
> postgis-devel at postgis.refractions.net
> http://postgis.refractions.net/mailman/listinfo/postgis-devel
>   




More information about the postgis-devel mailing list