full-text search configuration question

From: Andrew Geery <andrew(dot)geery(at)gmail(dot)com>
To: pgsql-general(at)postgresql(dot)org
Subject: full-text search configuration question
Date: 2010-06-08 20:27:07
Message-ID: AANLkTinvpIT_-h3nYLj3P6WBGIYEtSj5rAWZpjoUVlXU@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

I have several tables with text columns that contain information that
I would like to be able to search using a FTS index. For each text
column, there is also a column that is a foreign key into a language
table for the language used in the text. My idea is to add a column
to the language table to reference a FTS configuration for a given
language and to write a function to wrap a call to to_tsvector (after
looking up the given configuration name from the language) as per the
documentation [http://www.postgresql.org/docs/8.4/interactive/textsearch-tables.html]
However, functions used in indexes must be immutable and while the
FTS configuration probably wouldn't change very often for a given
language, I suppose it is possible.

My question is: am I better off putting a column in each table with
which I want to use FTS to store the FTS config name or can I get away
with pushing the FTS configuration name into the language table?

Thanks
Andrew

Browse pgsql-general by date

  From Date Subject
Next Message uaca man 2010-06-08 20:40:34 Re: Queues Problem
Previous Message Steve Crawford 2010-06-08 20:25:41 Re: Postgres 8.4 segfaults on CentOS 5.5 (using EnterpriseDB installers)