Search Postgresql Archives

Re: Searching a DB index.. possible?

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 11/02/10 17:11, Moe wrote:
You might want to summarize down to a separate (word,frequency) table.
Particularly if you don't want stemming to interfere with your suggestions.

Stemming is ok. That's fine.

How would this normally be implemented?  Should I go through my text word by
word myself, or the already existing index and copy over to a new table? Not
sure how this would be managable. Every change to something would require a
word count down, and then a word up after.

I wouldn't bother keeping it 100% up-to-date. You only want the most-plausible suggestions anyway. Have a look at the ts_stat() function.

http://www.postgresql.org/docs/8.4/interactive/textsearch-features.html

Run it overnight, and summarise to a separate table, then just use "like" against it.

Otherwise, like you say, your database will spend most of its time adding up word counts etc.

--
  Richard Huxton
  Archonet Ltd

--
Sent via pgsql-general mailing list (pgsql-general@xxxxxxxxxxxxxx)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-general

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Postgresql Jobs]     [Postgresql Admin]     [Postgresql Performance]     [Linux Clusters]     [PHP Home]     [PHP on Windows]     [Kernel Newbies]     [PHP Classes]     [PHP Books]     [PHP Databases]     [Postgresql & PHP]     [Yosemite]
  Powered by Linux