Re: TSearch and rankings

From: Teodor Sigaev <teodor(at)sigaev(dot)ru>
To: bas(at)scheffers(dot)net
Cc: pgsql-general(at)postgresql(dot)org
Subject: Re: TSearch and rankings
Date: 2004-02-09 14:40:07
Message-ID: 40279BC7.9060400@sigaev.ru
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

Bas Scheffers wrote:
> Hi,
>
> Is there a way to use tsearch so that it returns documents that have less
> than all the required keywords? The idea is that if a document only has 3
> out of 4 terms, it is still returned, but with a lower ranking.
>
> So far I haven't found a way to do this in the documentation. Is there
> something like a "maybe" operator? (ie: 'foo&bar&~doh', meaning documents
> with foo and bar, and optionaly doh, but those with would be ranked
> higher)

(foo&bar)|(foo&bar&doh)

I think, it's what you want.

--
Teodor Sigaev E-mail: teodor(at)sigaev(dot)ru

In response to

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Bas Scheffers 2004-02-09 15:15:03 Re: TSearch and rankings
Previous Message Bas Scheffers 2004-02-09 14:21:03 TSearch and rankings