Postgres Gurus: Insert a List as bulk?

Mark Phillips mark.phillips at mophilly.com
Tue Jul 23 11:15:29 EDT 2013


On Jul 23, 2013, at 2:36 AM, ADJob <mats at adjob.se> wrote:

> Hi,
> 
> We are about to write a routine that transfer the data from native datafile to Postgresql database. I have managed to do this, but it takes an eternity. And now I am searching a faster way to transfer all data and I have found three ways to do this:
> 
> 1. Loop within an object class from a prepared list (todays solution)
> 2. Using pv_LIST.$doinserts
> 3. Using COPY (= moving the loop to the Postgresql)

If you have not done so already, be sure to drop the indices and constraints and turn off auto commit. You can add the constraints after the data is loaded, then run the vacuum/index process to set things up. 

 - Mark Phillips






More information about the omnisdev-en mailing list