[Xapian-discuss] Proximity in Xapian?

Sharjeel Ahmed Qureshi sharjeel.ahmed at vahzay.com
Wed Dec 6 06:59:47 GMT 2006


Thats a little confusing. Shouldn't it be
"foo AND bar OR (foo NEAR/5 bar)" ?
              ^^
Because I think putting an AND will restrict to only those results in 
which foo, bar are five places apart. Please correct me if I am wrong.

Regards,
Sharjeel

Olly Betts wrote:
> On Tue, Dec 05, 2006 at 09:46:45PM -0800, Philip Neustrom wrote:
>> Another, probably more general, question would be:  How can
>> proximity-weighted searches be done with Xapian?
> 
> You could take a proximity-weighted query for "foo" and "bar" and
> generate a query like:
> 
>     foo AND bar AND (foo NEAR/5 bar)
> 
> That would match all documents with both "foo" and "bar" in, but give
> more weight to those where they occurred within 5 words of each other.
> 
> Cheers,
>     Olly
> 
> _______________________________________________
> Xapian-discuss mailing list
> Xapian-discuss at lists.xapian.org
> http://lists.xapian.org/mailman/listinfo/xapian-discuss
> 




More information about the Xapian-discuss mailing list