You are viewing a plain text version of this content. The canonical link for it is here.
Posted to java-user@lucene.apache.org by iv...@yahoo.com on 2005/05/06 00:07:48 UTC

Changing default "OR" to "AND" for QueryParser

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?


Thanks,

Slavikas

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


Parsnips 1.4

Posted by Bill Tschumy <bi...@otherwise.com>.
I have just released Parsnips 1.4, a commercial PIM for storage and  
retrieval of bookmarks, notes, file URLs and snippets of text.   
Parsnips is powered by Lucene.

Please have a look at: <http://www.otherwise.com/Parsnips.html>
-- 
Bill Tschumy
Otherwise -- Austin, TX
http://www.otherwise.com



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


Re: Changing default "OR" to "AND" for QueryParser

Posted by Richard Littin <ri...@reeltwo.com>.
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