Tsearch & functional indexes - Mailing list pgsql-general

From Ron Mayer
Subject Tsearch & functional indexes
Date
Msg-id diaq1n$2hgl$1@news.hub.org
Whole thread Raw
Responses Re: Tsearch & functional indexes  (Oleg Bartunov <oleg@sai.msu.su>)
List pgsql-general
In the tsearch2 documentation I see a lot of examples where you
add a column of type tsvector to your table and then indexing
that column.

Instead of adding the extra column, would it be possible to
just make a functional index something like this:

   create index foo__tsearch on foo using gist (to_tsvector('simple'::text, text))

A brief informal experiment I tried suggests that
the create index command works; but that queries
using this approach were slower than having the
column around.  I would have expected it to be faster,
since the disk space used should have been smaller.
Perhaps something about table statistics that I'm
not considering?

pgsql-general by date:

Previous
From: Zlatko Matić
Date:
Subject: pg_autovacuum
Next
From: Zlatko Matić
Date:
Subject: problems with upgrade from 8.0.3 to 8.0.4, Windows