Re: [PERFORM] Array interface

2010-11-10 Thread Mark Kirkwood
On 03/11/10 08:46, Mladen Gogala wrote: I wrote a little Perl script, intended to test the difference that array insert makes with PostgreSQL. Imagine my surprise when a single record insert into a local database was faster than batches of 100 records. Here are the two respective routines: I

Re: [PERFORM] Array interface

2010-11-10 Thread Mark Kirkwood
On 10/11/10 22:10, Mark Kirkwood wrote: What might also be interesting is doing each INSERT with an array-load of bind variables appended to the VALUES clause - as this will only do 1 insert call per "array" of values. This is probably more like what you were expecting: rowsnum values t

Re: [PERFORM] Array interface

2010-11-03 Thread Mladen Gogala
Conor Walsh wrote: I generally suspect this is a Perl problem rather than a Postgres problem, So do I. I had the same situation with Oracle, until John Scoles had the DBD::Oracle driver fixed and started utilizing the Oracle array interface. but can't say more without code. Maybe try pas

Re: [PERFORM] Array interface

2010-11-02 Thread Conor Walsh
On Tue, Nov 2, 2010 at 2:32 PM, Mladen Gogala wrote: > I was surprised because I expected array bind to produce better > results over the network than the row-by-row operations, yet it > didn't. Can anybody elaborate a bit? While all of the bulk-execute functions are likely to have implementatio