Skip site navigation (1) Skip section navigation (2)

Re: Speed Question

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: "scott(dot)marlowe" <scott(dot)marlowe(at)ihs(dot)com>
Cc: Noah Silverman <noah(at)allresearch(dot)com>,pgsql-performance(at)postgresql(dot)org
Subject: Re: Speed Question
Date: 2002-12-20 23:50:25
Message-ID: 25958.1040428225@sss.pgh.pa.us (view raw or flat)
Thread:
Lists: pgsql-performance
"scott.marlowe" <scott(dot)marlowe(at)ihs(dot)com> writes:
> On Fri, 20 Dec 2002, Noah Silverman wrote:
>> Issue #1:  Speed of inserts is relatively slow.  100000 inserts is 

> Are you doing these in a transaction?  If not, then try adding a 
> begin;end; pair around your inserts.  i.e.

> begin;
> insert 100000 rows
> end;

Or use a COPY command instead of retail inserts.  See also the tips at
http://www.ca.postgresql.org/users-lounge/docs/7.3/postgres/populate.html

> One is you might get some help from a multi-column index.

Yes, I'd recommend a multi-column index when no single column is
particularly selective.

			regards, tom lane

In response to

pgsql-performance by date

Next:From: Josh BerkusDate: 2002-12-20 23:59:23
Subject: Re: Speed Question
Previous:From: scott.marloweDate: 2002-12-20 23:23:59
Subject: Re: Speed Question

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group