[Xapian-discuss] "and" without boolean operators
James Aylett
james-xapian at tartarus.org
Mon Dec 31 17:14:50 GMT 2007
On Mon, Dec 31, 2007 at 05:49:10PM +0100, double wrote:
> I am using Xapian::QueryParser() to create the Query. The flags are:
> FLAG_PHRASE | FLAG_LOVEHATE | FLAG_WILDCARD
>
> If I search, lets say for "king queen" (without quotes), I get all documents
> with either "king" or "queen". Is there a chance to find only documents with
> "king" and "queen" without boolean operators (like Google)?
Try the following (or equivalent in your language):
----------------------------------------------------------------------
query_parser.set_default_op(Xapian::Query::OP_AND);
----------------------------------------------------------------------
J
--
/--------------------------------------------------------------------------\
James Aylett xapian.org
james at tartarus.org uncertaintydivision.org
More information about the Xapian-discuss
mailing list