Tsearch2 / Create rule on select

Поиск
Список
Период
Сортировка
От Jean-Michel Pouré
Тема Tsearch2 / Create rule on select
Дата
Msg-id 1173387383.12072.12.camel@localhost
обсуждение исходный текст
Ответы Re: Tsearch2 / Create rule on select  (Magnus Hagander <magnus@hagander.net>)
Список pgsql-general
Dear Friends,

I am very impressed by TSearch2 and would like to thank Oleg and the
team for their hard work.

I would like to migrate a phpBB forum with more that 200.000 messages to
TSeach. Full text searches have become a bottleneck. When there are more
than 200 users, the server slow dramatically. I need TSearch!

So ... I installed TSearch2, a French dictionnary, everything is okay.
My database is PostgreSQL 8.2.3, UTF-8.

My questions now:
1) Should I migrate phpBB to TSeach2 in PHP code, rewriting the queries,
which is quite obvious or easy.

OR

2) Is there a smart way to catch queries on the fly in PostgreSQL, for
example using

"CREATE RULE "_RETURN" AS
    ON SELECT TO t1
    DO INSTEAD "

or the like.

The idea would be that when I search on a text field, PostgreSQL rule system would rewrite the query to seach using
Tsearch2. 
Is there any tool in TSeach2 doing this query rewriting rule?
Obviously, it does not seem to exist, but I would like to be sure.

3) Gin indexes
Are Gin indexes recommended for large databases?
How to calculate the size in memory of an index?

Kind regards,
Jean-Michel


В списке pgsql-general по дате отправления:

Предыдущее
От: "Stuart Cooper"
Дата:
Сообщение: Re: Can psql show me where my script is broken?
Следующее
От: D Unit
Дата:
Сообщение: Solaris and Ident