Re: tsearch (or related) question - Mailing list pgsql-general

From Tom Lane
Subject Re: tsearch (or related) question
Date
Msg-id 7700.1295025261@sss.pgh.pa.us
Whole thread Raw
In response to tsearch (or related) question  (Satoshi Nagayasu <satoshi.nagayasu@gmail.com>)
List pgsql-general
Satoshi Nagayasu <satoshi.nagayasu@gmail.com> writes:
> I want to hit a row when I use 'a&b' or 'b&c' in a tsquery,
> but not 'a&c'.

Wouldn't this do it?

    tsvectorcol @@ '(a&b | b&c) & !(a&c)'

            regards, tom lane

pgsql-general by date:

Previous
From: Vick Khera
Date:
Subject: Re: Question about concurrent synchronous and asynchronous commits
Next
From: Alban Hertroys
Date:
Subject: Re: Record with a field consisting of table rows