[GENERAL] Full text search and count

2008-02-07 Thread lbarcala
Hello: I have been reading and testing some issues of postgres 8.3 and I have a doubt: Is there any way to obtain the number of hits of a full text query? I have seen that I can highlight the matching tokens but, what about to count the number of tokens that verify a full text query? Is it possib

Re: [GENERAL] multi-word expression full-text searching

2008-07-01 Thread lbarcala
> > SELECT id FROM document WHERE to_tsvector('english',text) @@ > plainto_tsquery('english','despite this'); > -- > Teodor Sigaev If I understand well the plainto_tsquery behaviour, this query match with: Despite this, the president went out. Despite the event, this question arise. i.e., if "th

[GENERAL] Functional index adding one

2008-07-03 Thread lbarcala
Hi all: I'm trying to create a functional index into column position of token table (see below). I want to make something like: CREATE INDEX token_position_func ON token (position+1); but I get: test=# CREATE INDEX token_position_func test-# ON token (position+1); ERROR: syntax error at or nea

[GENERAL] Full text index without accents

2008-07-03 Thread lbarcala
Hi again: I am trying to create a full text configuration to ignore word accents in my searches. My approach is similar to simple dicionary one, but i want to remove accents after converting to lower. Is it the only way to do it to develop another .c and write my own dict_noaccent.c, and then com