I am using Solr
5.2.1, in one of my project, and got some doubt on mm
paramter of dismax
/ edismax
parser.
Questions:
- Does
mm
regardless of total input term count? Document says yes, but when I set it to 3, and input a single term, it still could get records, so it seems not regardless of total input term count. - What is the default value of
mm
? Document says it's100%
, but in my query test, it seems to be1
. By the way, I didn't found configuration formm
insolrconfig.xml
orschema.xml
.
Any help? Thx.
@Update:
Query url for 1st question:
http://localhost:8983/solr/demo/select?q=new+york&start=0&wt=json&indent=true&defType=edismax&qf=title&mm=3&stopwords=true&lowercaseOperators=true
There are 2 terms new
and york
, the query result is:
- don't specify
mm
, return 3 records, mm
= 2, return 1 records,mm
= 3, also return 1 records,
So, I guess it will change the mm to max term first, before query.
Answer-2:
If nomm
parameter is specified in the query, or as a default insolrconfig.xml
, the effective value of theq.op
parameter (either in the query, as a default in solrconfig.xml, or from the 'defaultOperator' option in schema.xml) is used to influence the behavior. So the default behavior of themm
is determined byq.op
parameter. Ifq.op
is effectivelyAND
, thenmm=100%
; ifq.op
isOR
, thenmm=1
.