From: | Martijn van Oosterhout <kleptog(at)svana(dot)org> |
---|---|
To: | Pat Maddox <pergesu(at)gmail(dot)com> |
Cc: | pgsql-general(at)postgresql(dot)org |
Subject: | Re: How can I speed up this query? |
Date: | 2006-06-28 08:05:11 |
Message-ID: | 20060628080511.GB29253@svana.org |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-general |
On Wed, Jun 28, 2006 at 01:52:10AM -0600, Pat Maddox wrote:
> I end up calling this query quite often, so I need a way to speed it
> up. Don't know if I can take advantage of indexes or better joins or
> something (I don't even know if there are better joins), I'm really a
> newbie to DB stuff. Hoping somebody can help me make this much
> quicker.
<snip>
> -> Index Scan using
> trainer_hand_results_trainer_scenario_id_index on trainer_hand_results
> r (cost=0.00..19.12 rows=570 width=44) (actual time=415.677..420.197
> rows=578 loops=1)
That's an awful long time to find a few rows in a table via an index.
How big is this table/index?
What version is this? If you have a older version perhaps you're
suffering from index bloat and you need to REINDEX that table/index.
Hope this helps,
--
Martijn van Oosterhout <kleptog(at)svana(dot)org> http://svana.org/kleptog/
> From each according to his ability. To each according to his ability to litigate.
From | Date | Subject | |
---|---|---|---|
Next Message | Thomas Hallgren | 2006-06-28 08:22:45 | Re: UUID's as primary keys |
Previous Message | Pat Maddox | 2006-06-28 07:52:10 | How can I speed up this query? |