Transferred from: http://www.cnblogs.com/chenying99/archive/2012/07/24/2607339.html
1. Standard (StandardRequestHandler)
The standard Query Analyzer uses Solrquerysyntax to specify the query by using the Q parameter, which requires a good organization (formed), or returns an exception. For precise queries and arbitrarily complex queries, the standard effect is good.
2. Dismax (Dismaxrequesthandler)Dismax Query Analyzer is a more tolerant query parser provided to the user, and the query string is passed directly to a Q parameter. Other parameters can be easily searched across multiple fields, using disjunctions and a non-strict phrase query to return highly correlated results. The "partial match" here means that the returned result does not exactly match all the search keywords.
The dismaxqparserpluign has a parameter of mm (Minimum ' should ' match), which sets the minimum number of matches to be matched throughout the search keyword. Here's an example.
"2": regardless of the total number of keywords, doc must match the minimum of 2
"75%": Doc needs to match 75% of the key words, the number of key words is rounded down.
"2<-25%": When the keyword is less than 3, Doc needs to match all, or more than 3, Doc needs to match at least 75%
"2<-1 5<80%": keyword less than 3 times, need to match all, 3-5 times, there can only be one mismatch; more than 5 times, the minimum need to match 80%
The default mm is 100%, which means that all keywords must have a match. Even if you set operator to or in the Schema.xml, you also have to be limited by MM, that is, doc that cannot match all the keywords is not in the result set.
3./MLT (Morelikethishandler)
Morelikethis query, also called the text to find the text.
4./dataimport (Dataimporthandler)
Data import request processing, you need to configure the appropriate data source configuration file:
<str name= "config" >data-config.xml</str>
5./update (Xmlupdaterequesthandler)
Update document request Processing
6./analysis (Analysisrequesthandler)Parsing request Processing
the difference between standard and Dismax
- Standard requires that the query content entered conforms to the Solrquerysyntax query syntax and that special characters are escaped. If you do not conform to the syntax, you will get an error. Dismax query will not have such a problem, for the user's input will always not error.
- How do I find an index containing Superman in the title and subject two field?
- The standard request handler uses Solrquerysyntax for Q:
- Q=title:superman Subject:superman
- Using the Dismax request handler, specify the query fields using the QF param.
- Q=superman&qf=title subject
- How do I get the title field's scoring weight higher than the subject field?
- For the standard request handler, the "boost" of the clause on the title field:
- Q=title:superman^2 Subject:superman
- Using The Dismax request handler, one can specify boosts on fields in parameters such as QF:
- Q=superman&qf=title^2 subject
About SOLR Concepts: Solrrequesthandler