Allows clients to specify a Lucene query to identify a set of documents. If non-blank,the explain info of each document which matches this query, relative to the main query (specified by the q parameter) will be returned along with the rest of the debugging information.
timeAllowed
指定查询处理的时间,单位毫秒。如果查询在指定的时间未完成,则只返回部分信息
segmentTerminateEarly
Indicates that, if possible, Solr should stop collecting documents from each individual (sorted) segment once it can determine that any subsequent documents in that segment will not be candidates for the rows being returned. The default is false.
(jakarta OR apache) AND website 查询jakarta或apache出现,并且website必须出现 title:(+return +"pink panther") 查询title中包含return和“pink panther”
6. 查询语句中使用注释
solr的查询语句支持C语言格式的注释。 "jakarta apache" /* this is a comment in the middle of a normal query string */ OR jakarta
7. 时间和日期的表示
timestamp:[* TO NOW] createdate:[1976-03-06T23:59:59.999Z TO *] createdate:[1995-12-31T23:59:59.999Z TO 2007-03-06T00:00:00Z] pubdate:[NOW-1YEAR/DAY TO NOW/DAY+1DAY] createdate:[1976-03-06T23:59:59.999Z TO 1976-03-06T23:59:59.999Z+1YEAR] createdate:[1976-03-06T23:59:59.999Z/YEAR TO 1976-03-06T23:59:59.999Z]
8. solr标准的查询解析与Lucene的查询解析的不同点如下:
*号可以用在范围查询的开始或结束 field:[* TO 100] field值小于等于100 field:[100 TO *] field值大于等于100 field:[* TO *] 匹配包含field字段的所有文档
支持单独出现的否定查询 -inStock:false field值inStack是false -field:[* TO *] 匹配field无值的所有文档