What is dismax query parser and how to use it. I just want to search for a string in a field in solr by its matching percentage. how to use it getting this done. Please give an example how to use dismax query parser.
i have the following document. and i just to get the document which matches fully or partially with the q=Jain Nagar Bla Bla
{
"id":"2",
"shipping_firstname":"Sudhanshu",
"address":"H.No. 444, Gali No.2 Jain Nagar",
"date_added":"2017-01-21T14:15:15Z",
"_version_":1562029999829024768}]
}
I am using this query
select?q=Jain Nagar&defType=dismax&mm=2&pf=address&qf=address
Why it doesn't give any result.
Try
mm(Minimum Should Match) Parameter of dismax parser.it has great flexibility to specify Integers or percentage to mm parameter.
Example:
consider 3 docs
Lets say query
ipod apple. it retrieve docs if it has term eitheripodorappleor both. so we get 3 results.if we use mm=2 with dismax parser
It fetch docs minimum match of 2 words, specified in query
ipod apple. if doc has only one term (say 'ipod') it wont be returned in results.In result we get only one doc, i.e
can also specify percentage values to
mmparameter(like 75% or -25%)for more details check Here
Hope this helps, vinod