tsearch query plan - Mailing list pgsql-performance

From Mark Lubratt
Subject tsearch query plan
Date
Msg-id D8C70D62-8982-11D8-90A0-000A9579AF50@indeq.com
Whole thread Raw
Responses Re: tsearch query plan
List pgsql-performance
Hello,

I've just started using the tsearch2 system.  I'm VERY impressed by the
speed.

I've got one question about query planning.  Is it understandable to
have the query plan estimation be off by a couple of orders of
magnitude?  Or, is it the fact that the cost estimation is small to
begin with that the error between the actual and the estimated is
"normal"?

Here is my explain analyze run immediately after a vacuum full analyze:

kjv=# vacuum full analyze;
VACUUM
kjv=# explain analyze select * from kjv where idxFTI @@
'corinth'::tsquery;
                                                      QUERY PLAN
------------------------------------------------------------------------
---------------------------------------------
  Index Scan using idxfti_idx on kjv  (cost=0.00..125.44 rows=32
width=193) (actual time=0.796..1.510 rows=6 loops=1)
    Index Cond: (idxfti @@ '\'corinth\''::tsquery)
    Filter: (idxfti @@ '\'corinth\''::tsquery)
  Total runtime: 1.679 ms
(4 rows)

Thanks!
Mark


pgsql-performance by date:

Previous
From: Robert Treat
Date:
Subject: Re: Postgresql educational sources
Next
From: "Jaime Casanova"
Date:
Subject: Re: statistics