Обсуждение: How to remove the possibility to search the parts of a compound word with hyphen

Поиск
Список
Период
Сортировка

How to remove the possibility to search the parts of a compound word with hyphen

От
"Fco. Mario Barcala" Rodríguez
Дата:
Hi all:

I have been searching the mailing lists about hyphens but I coudn't find
the answer to this question:

Is it possible to remove the possibility of searching the parts of a
word which include a hyphen? I know that the default parser identifies
all possibilities (the compound word and the individual part ones), but
I would like to make possible to search only for the compound word, but
not for the parts.

Using one example of the parsers section in documentation, i would like
to make possible to search lógico-matemática but not lógico or
matemática individually.

Would have I to write a new parser or are there any configuration issues
to do this?

Thanks,

  Mario Barcala


Re: How to remove the possibility to search the parts of a compound word with hyphen

От
Tom Lane
Дата:
"Fco. Mario Barcala" =?ISO-8859-1?Q?Rodr=EDguez?= <lbarcala@freeresearch.org> writes:
> Is it possible to remove the possibility of searching the parts of a
> word which include a hyphen? I know that the default parser identifies
> all possibilities (the compound word and the individual part ones), but
> I would like to make possible to search only for the compound word, but
> not for the parts.

Sure, just set up your text search configuration so that word-parts are
discarded instead of being passed through to the dictionary(s).

            regards, tom lane