[Xapian-discuss] Where do I stick the PARTIAL flag in xappy?

James Aylett james-xapian at tartarus.org
Fri Jun 10 16:25:28 BST 2011


On 10 Jun 2011, at 16:11, Peter Bengtsson wrote:

> I want to be able to do searches with FLAG_PARTIAL and some without. Most searches without but with the PARTIAL for an autocomplete widget. 
> 
> I'm using xappy and I can't find where to send the flag when I build up the query.


I don't believe this is currently possible with xappy; FLAG_PARTIAL and friends are provided to the parse_query() method on QueryParser, which xappy hides away. You can probably hack something by fiddling with "constants" in xappy.searchconnection.SearchConnection:

xappy.searchconnection.SearchConnection._qp_flags_base |= xapian.QueryPasrser.FLAG_PARTIAL

or something; that's pretty evil though :-)

Richard may be able to comment further.

>  The docs talk of setting up the database with or without FLAG_PARTIAL but that's probably not what I want. 

Don't know where you're seeing that; I can't find FLAG_PARTIAL in the xappy source code at all, or in the docs.

J

-- 
 James Aylett
 talktorex.co.uk - xapian.org - devfort.com




More information about the Xapian-discuss mailing list