lucene-java-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From syedfa <>
Subject Difference between PhraseQuery and Span(Near)Query
Date Fri, 18 Jun 2010 22:18:09 GMT

Dear fellow Java developers:

I am reading up on PhraseQuery to search for an exact match for terms that
appear exactly in a particular order for a field (i.e. slop value of 0). 
However, I came across SpanNearQuery which appears to work in a similar
fashion, but am confused, due to it's variations.  Can SpanNearQuery, or
SpanQuery also be used to find an exact match for a phrase provided by the
user?  What are the differences between SpanNearQuery(and SpanQuery for that
matter), and PhraseQuery, and when should I use each Query?

Thanks in advance to all who reply.


View this message in context:
Sent from the Lucene - Java Users mailing list archive at

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message