On Tue, Nov 17, 2009 at 11:09:38AM -0800, Chris Hostetter said:
> 
> Several things about your message don't make sense...
Hmm, sorry - a byproduct of building up the mail over time I think.

The query 

?q="Here there be dragons"
&fl=id,title,score
&debugQuery=on
&qt=dismax
&qf=title

gets echoed as 

<lst name="params">
 <str name="qf">title</str>
 <str name="fl">id,title,score</str>
 <str name="debugQuery">on</str>
 <str name="q">"Here there be dragons"</str>
 <str name="qt">dismax</str>
</lst>

and gets parsed as 

+DisjunctionMaxQuery((title:"here dragon")~0.01) ()

and gets no results.


Whereas 

?q=Here there be dragons
&fl=id,title,score
&debugQuery=on
&qt=dismax
&qf=title

gets echoed as 

<lst name="params">
<str name="debugQuery">on</str>
<str name="fl">id,title,score</str>
<str name="q">Here, there be dragons</str>
<str name="qf">title</str>
<str name="qt">dismax</str>
</lst>

and parsed as 

+((DisjunctionMaxQuery((title:here)~0.01) 
DisjunctionMaxQuery((title:dragon)~0.01))~2) ()

Gets one result

<doc>
<float name="score">6.3863463</float>
<str name="id">20980889</str>
<str name="title">Zelazny, Roger - Here There Be Dragons</str>
</doc>


It looks like it might be related to 

SOLR-879: Enable position increments in the query parser and fix the
          example schema to enable position increments for the stop 
          filter in both the index and query analyzers to fix the bug 
          with phrase queries with stopwords. (yonik)

http://issues.apache.org/jira/browse/SOLR-879

Although I added enablePositionIncrements="true" to

<filter class="solr.StopFilterFactory" ignoreCase="true" words="stopwords.txt"/>

in to the <analyzer type="query"> for <fieldType name="text"> in the 
schema which didn't fix it - I presume this means that I have to reindex 
everything (although the StopFilterFactory in <analyzer type="index"> 
already had it).



Reply via email to