From: | Alex Neth <alex(at)liivid(dot)com> |
---|---|
To: | pgsql-general(at)postgresql(dot)org |
Subject: | Full text index not being used, even though it is in the plan |
Date: | 2009-02-01 15:56:17 |
Message-ID: | 7D12FB69-F053-40B5-A214-174C03CD8B82@liivid.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-general |
I am trying to use a full text index, but it seems to be reindexing on
every query.
The query plan looks fine, but the queries take extremely long (hours
even). I think it is reindexing because it is notifying me that
certain long "words" won't be indexed as you can see below, which is
what it does when I create the index.
=> explain select id from source_listings where
plainto_tsquery('view') @@ to_tsvector('english', full_listing);
QUERY PLAN
--------------------------------------------------------------------------------------------------------
Bitmap Heap Scan on source_listings (cost=1454.88..7445.47
rows=1595 width=4)
Recheck Cond: (plainto_tsquery('view'::text) @@
to_tsvector('english'::regconfig, full_listing))
-> Bitmap Index Scan on kw2_index (cost=0.00..1454.48 rows=1595
width=0)
Index Cond: (plainto_tsquery('view'::text) @@
to_tsvector('english'::regconfig, full_listing))
=> explain analyze select id from source_listings where
plainto_tsquery('view') @@ to_tsvector('english', full_listing);
NOTICE: word is too long to be indexed
DETAIL: Words longer than 2047 characters are ignored.
NOTICE: word is too long to be indexed
DETAIL: Words longer than 2047 characters are ignored.
... it just keeps building a new index until I kill it
Cancel request sent
From | Date | Subject | |
---|---|---|---|
Next Message | Alex | 2009-02-01 16:32:58 | Re: Full text index not being used |
Previous Message | Russ Brown | 2009-02-01 14:33:59 | Re: PGSQL or other DB? |