End User Query Grammar Guide
From DBSight Full-Text Search Engine/Platform Wiki
| Table of contents |
AND mode search grammar
value
Just some text. Since the current mode is already AND.
+ sign
This "+" is actually not applied. Since the current mode is already AND.
- sign
"-" sign prevent documents with following terms from appearing in the result set.
field:value
By default, any "value" without a qualifying field searched on all fields. User can apply the value to a specific field by using field:value.
It can be combined with "+" and "-" together.
"value1 value2 value3"
The whole phrase is searched, instead of each words separately. It can be combined with "+" and "-" together.
value1 value2 value3
All the words are searched and "AND"ed.
"value1 value2"~n
In the matching document, value1 and value2 appear within n words of each other.
abc*
It can match abc, abcd, abce, abcdef, etc
abc?
It can match abcd, abce, etc.
Numeric Range Query
If "price" is a Keyword, Number type, the grammar will be like this
price:[10,) #price >= 10 price:[10,14.5] #price >= 10 and price <= 14.5 price:[10,14.5) #price >= 10 and price < 14.5 price:(10,14.5] #price > 10 and price <= 14.5 price:(10,14.5) #price > 10 and price < 14.5 price:(,9.8] #price <= 9.8
For Date Range Query, if "updated_at" is a Keyword, "Date"/"DateTime"/"Time" type, the grammar will be like this
updated_at:[2006/03/15,) #updated_at later or equal to 2006/03/15 updated_at:[2006/03/15,2006/04/15) #updated_at between 2006/03/15 and 2006/04/15(not inclusive)
If you still like Lucene Query Parser
Appending "&lucene=y" to the URL will turn it into Lucene Query Parser mode
