Re: Index Performance Help

From: Greg Stark <gsstark(at)mit(dot)edu>
To: "Damien Dougan" <damien(dot)dougan(at)mobilecohesion(dot)com>
Cc: <pgsql-performance(at)postgresql(dot)org>
Subject: Re: Index Performance Help
Date: 2004-04-02 04:44:29
Message-ID: 87d66rouoi.fsf@stark.xeocode.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-performance


"Damien Dougan" <damien(dot)dougan(at)mobilecohesion(dot)com> writes:

> Sample analyze output for an initial query:
>
> hydradb=# explain analyze select * from pvsubscriber where actorid =
> 'b3432-asdas-232-Subscriber793500';

I take it pvsubscriber is a view? What's the definition of your view?

> -> Index Scan using mc_actor_key on mc_actor
> (cost=0.00..4.08 rows=1 width=69)
> (actual time=39.497..39.499 rows=1 loops=1)

Is this table regularly vacuumed? Is it possible it has lots of dead records
with this value for actorid? Try running vacuum full, or better "vacuum full
verbose" and keep the output, it might explain.

What version of postgres is this? You might try reindexing all your indexes
(but particularly this one). Older versions of postgres were prone to index
bloat problems.

--
greg

In response to

Browse pgsql-performance by date

  From Date Subject
Next Message Greg Stark 2004-04-02 04:59:46 Re: single index on more than two coulumns a bad thing?
Previous Message Tom Lane 2004-04-02 04:36:38 Re: single index on more than two coulumns a bad thing?