search_query.md
1.24 KB
Query
To perform specific Mtas queries in Solr requests, the following parameter should be used.
Parameter | Value | Obligatory |
---|---|---|
mtas | true | yes |
See statistics, kwic, list, document, termvector, facet, group and prefix for more details and examples.
Regular queries
Besides from specific Mtas queries in Solr requests, also CQL can be used in regular queries by configuring the Mtas query parser in solrconfig.xml.
Example 1
Search for documents containing the word "de" with a query.
q={!mtas_cql+field%3D"text"+query%3D"[t%3D\"de\"]"}&fl=*&start=0&rows=0&wt=json&indent=true
"response":{"numFound":1664241,"start":0,"docs":[]
}
Example 2
Search for documents containing the word "de" with a filter query.
fq={!mtas_cql+field%3D"text"+query%3D"[t%3D\"de\"]"}&q=*%3A*&fl=*&start=0&rows=0&wt=json&indent=true
"response":{"numFound":1664241,"start":0,"docs":[]
}