Looks like AND is your defaultOperator [1]. Check your schema.xml and try 
adding q.op=or to your query.

[1]: http://wiki.apache.org/solr/SearchHandler#q.op
 
On Thursday 09 September 2010 15:34:52 Stéphane Corlosquet wrote:
> Hi all,
> 
> I'm new to solr so please let me know if there is a more appropriate place
> for my question below.
> 
> I'm noticing a rather unexpected number of results when I add more keywords
> to a search. I'm listing below a example (where I replaced the real
>  keywords with placeholders):
> 
> keyword1 851 hits
> keyword1 keyword2  90 hits
> keyword1 keyword2 keyword3 269 hits
> keyword1 keyword2 keyword3 keyword4 47 hits
> 
> As you can see, adding k2 narrows down the amount of results (as I would
> expect), but adding k3 to k1 and k2 suddenly increases the amount of
> results. with 4 keywords, the results have been narrowed down again. Would
> solr/lucene search algorithm with multiple keywords explain this non
> consistent behavior? I would think that adding more keywords would narrow
> down my results.
> 
> I'm pasting below the relevant log in case it helps:
> 
> INFO: [] webapp=/solr path=/select/
> params={spellcheck=true&facet=true&facet.mincount=1&facet.limit=20&spellche
> ck.q=keyword1+keyword2+keyword3+keyword4&
>  json.nl=map&wt=json&version=1.2&rows=10&fl=id,nid,title,comment_count,type
> ,created,changed,score,path,url,uid,name&start=0&facet.sort=true&q=keyword1
> +keyword2+keyword3+keyword4&bf=recip(rord(created),4,10704,10704)^200.0&fac
> et.field=im_cck_field_author&facet.field=type&facet.field=im_vid_1=&indent=
> on&start=0&version=2.2&rows=10} hits=10704 status=0 QTime=1
> 
> any hint on whether this is expected or not appreciated.
> 
> Steph.
> 

Markus Jelsma - Technisch Architect - Buyways BV
http://www.linkedin.com/in/markus17
050-8536620 / 06-50258350

Reply via email to