lucene-general mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Mike Korcynski <>
Subject Re: exact match on a stored / tokenized field.
Date Thu, 21 May 2009 21:41:52 GMT

I've got one follow up question to my previous questions.  What is the 
best way to just get a yes or no does this field match the query, 
regardless of whether its AND, OR or exact phrase I want it to evaluate 
the query and return a 0 or no if doesn't and 1 or true if it does.  
I've been using the Highlighter and calling getBestFragment and if it 
returns a fragment I assume it's found a match but ultimately it seems 
to match OR when I want AND, although it does work for exact phrase.  
I'm looking at the scores from the SpanScorer and the Highlighter is 
returning fragments for fields that have a score of 0 which seems odd 
but I'm guessing I'm misusing something.  I just want a simple yes/no 
match on the query against the field.

Thanks for the help.


View raw message