Re: Quad Opteron stuck in the mud

From: Simon Riggs <simon(at)2ndquadrant(dot)com>
To: Dan Harris <fbsd(at)drivefaster(dot)net>
Cc: pgsql-performance(at)postgresql(dot)org
Subject: Re: Quad Opteron stuck in the mud
Date: 2005-07-13 22:51:16
Message-ID: 1121295076.3970.381.camel@localhost.localdomain
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-performance

On Wed, 2005-07-13 at 12:54 -0600, Dan Harris wrote:
> For example, as I'm writing this, I am running an UPDATE statement
> that will affect a small part of the table, and is querying on an
> indexed boolean field.

An indexed boolean field?

Hopefully, ftindex is false for very few rows of the table?

Try changing the ftindex to be a partial index, so only index the false
values. Or don't index it at all.

Split the table up into smaller pieces.

Don't use an UPDATE statement. Keep a second table, and insert records
into it when you would have updated previously. If a row is not found,
you know that it has ftindex=true. That way, you'll never have row
versions building up in the main table, which you'll still get even if
you VACUUM.

Best Regards, Simon Riggs

In response to

Browse pgsql-performance by date

  From Date Subject
Next Message jobapply 2005-07-13 23:46:23 Indexing Function called on VACUUM and sorting ?
Previous Message jobapply 2005-07-13 22:35:10 Functional index is 5 times slower than the basic one