On 12/12/2012 10:27 AM, Burgmans, Tom wrote:
I have set <solrQueryParser defaultOperator="AND"/> in the schema (and 
restarted Solr), and tested again with

http://localhost:8983/solr/collection1/browse?defType=edismax&q=(Thomas+Michael)+OR+xxxmatchesnothingxxx&q.op=AND

note the extra parameter. Still it returns the 7 documents that matches (Thomas 
OR Michael), but not (Thomas AND Michael).

The only way to enforce an implicit AND is by changing the query into

http://localhost:8983/solr/collection1/browse?defType=edismax&q=(%2BThomas+%2BMichael)+OR+%2Bxxxmatchesnothingxxx

But then the AND isn't implicit anymore...and I don't like to prefix all my 
search terms with a +.

It smells like a bug to me, so you should probably file an issue in Jira. I will admit that this is getting somewhat outside my experience level.

I noticed the /browse there ... is this just what you have named your handler, or is this connected with the Velocity stuff?

Have you tried adding &debugQuery=true to your URL and seeing what your different queries actually parse to? It may also be a good idea to add &echoParams=all so you can see all parameters that are going into the request.

Thanks,
Shawn

Reply via email to