lucene-java-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Richard Littin <rich...@reeltwo.com>
Subject Re: Changing default "OR" to "AND" for QueryParser
Date Thu, 05 May 2005 22:40:46 GMT
ivj2324234-lucene@yahoo.com wrote:
> Hello all,
> 
> For us "OR" defaul causes confusion among the users 
> because they expect narrower results as they add to 
> the query but the oppsite happens because the terms 
> are or-ed.
> 
> It it possble to request QueryParser to use "AND" as 
> a default instead of "OR"? What API call(s) is
> responsible for this?

QueryParser parser = new QueryParser(...);
parser.setOperator(DEFAULT_OPERATOR_AND);

Richard

> 
> 
> Thanks,
> 
> Slavikas
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: java-user-unsubscribe@lucene.apache.org
> For additional commands, e-mail: java-user-help@lucene.apache.org
> 
> 
> .
> 


-- 
Richard Littin, Reel Two NZ, PO Box 1538, Hamilton, New Zealand
richard@reeltwo.com - ph: +64 7 857 0703 - fax: +64 7 857 0701
void main(){float x=0;while(putchar((long)((x<4)?(((6.6667*x-34.5)
*x+50.8333)*x+++82):(((-7.5*x+97)*x-398.5)*x+++619)))-10);}

---------------------------------------------------------------------
To unsubscribe, e-mail: java-user-unsubscribe@lucene.apache.org
For additional commands, e-mail: java-user-help@lucene.apache.org


Mime
View raw message