[ https://issues.apache.org/jira/browse/LUCENE-1931?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12760265#action_12760265 ]
Yonik Seeley commented on LUCENE-1931: -------------------------------------- Just return null from Weight.scorer() and you can remove the NoHitsScorer. Of course, one could always just use this_field_doesnt_exist:foo or from java code, something like new TermQuery(new Term("-","-")) > no hits query - query object that returns no hits > ------------------------------------------------- > > Key: LUCENE-1931 > URL: https://issues.apache.org/jira/browse/LUCENE-1931 > Project: Lucene - Java > Issue Type: New Feature > Components: Search > Affects Versions: 2.9 > Reporter: John Wang > Attachments: nohitsquery.patch > > > Query implementation that return no hits. -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online. --------------------------------------------------------------------- To unsubscribe, e-mail: java-dev-unsubscr...@lucene.apache.org For additional commands, e-mail: java-dev-h...@lucene.apache.org