Search Postgresql Archives

Re: fts, compond words?

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

 



That is a long discussed thing. We can't formulate unconflicting rules... For example:
1) a  &[dist<=2]  ( b &[dist<=3] c )
2) a  &[dist<=2]  ( b |[dist<=3] c )
3) a  &[dist<=2] !c
4) a  &[dist<=2]  ( b |[dist<=3] !c )
5) a  &[dist<=2] ( b & c )
What does exact they mean? What is tsvectors which should be matched by those queries?

The simple solution is : under operation 'phrase search' (ok, it will be '+' below) it must be only 'phrase search operations. I.e.:
a | b ( c + ( d + e ) )      - good
a | ( c + ( d & g ) ) 	     -  bad.

For example, we have word 'foonish' and after lexize we got two lexemes: 'foo1' and 'foo2'. So a good query 'a + foonish' becomes 'a + ( foo1 | foo2 )'...





Mike Rylander wrote:
On 12/6/05, Marcus Engene <mengpg@xxxxxxxxx> wrote:

[snip]


 A & (B | (New OperatorTheNextWordMustFollow York))



Actually, I love that idea.  Oleg, would it be possible to create a
tsquery operator that understands proximity?  Or, how allowing a
predicate to the current '&' op, as in '&[dist<=1]' meaning "next
token follows with a max distance of  1".  I imagine that it would
only be useful on unstripped tsvectors, but if the lexem position is
already stored ...

--
Mike Rylander
mrylander@xxxxxxxxx
GPLS -- PINES Development
Database Developer
http://open-ils.org

---------------------------(end of broadcast)---------------------------
TIP 2: Don't 'kill -9' the postmaster

--
Teodor Sigaev                                   E-mail: teodor@xxxxxxxxx
                                                   WWW: http://www.sigaev.ru/


[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