Re: Optimizing a complex query (long) - Mailing list pgsql-general

From Tom Lane
Subject Re: Optimizing a complex query (long)
Date
Msg-id 27965.1004126990@sss.pgh.pa.us
Whole thread Raw
In response to Optimizing a complex query (long)  (Paulo Jan <admin@digital.ddnet.es>)
List pgsql-general
Paulo Jan <admin@mail.ddnet.es> writes:
> The problem that I'm having is that the
> search on text fields is too slow,

The only way to make that acceptably fast is to build an index designed
specially for text searches.  A simple index will only help for queries
like field = 'foo', not field ~ 'foo'.

The contrib/fti module is one possible approach (a rather inelegant one,
but a lot of people are using it).  In 7.2 there will be a new
contrib/tsearch module that is allegedly better, though I haven't
played with it myself.  If fti seems too grotty you might want to
download the new 7.2 beta release to try out.

            regards, tom lane

pgsql-general by date:

Previous
From: Tom Lane
Date:
Subject: Re: initdb segfault - solaris 8
Next
From: "Eric Ridge"
Date:
Subject: Re: Sorting by parent/child relationships