Merge pull request #1742 from druid-io/add-search-filter

add docs for search filter
This commit is contained in:
Gian Merlino 2015-09-16 16:09:35 -07:00
commit aed7cab11e
1 changed files with 38 additions and 0 deletions

View File

@ -110,3 +110,41 @@ The following matches dimension values in `[product_1, product_3, product_5]` fo
}
}
```
### Search filter
Search filters can be used to filter on partial string matches.
```json
{
"filter": {
"type": "search",
"dimension": "product",
"query": {
"type": "insensitive_contains",
"value": "foo"
}
}
}
```
|property|description|required?|
|--------|-----------|---------|
|type|This String should always be "search".|yes|
|dimension|The dimension to perform the search over.|yes|
|query|A JSON object for the type of search. See below for more information.|yes|
#### Search Query Spec
##### Insensitive Contains
|property|description|required?|
|--------|-----------|---------|
|type|This String should always be "insensitive_contains".|yes|
|value|A String value to run the search over.|yes|
##### Fragment
|property|description|required?|
|--------|-----------|---------|
|type|This String should always be "fragment".|yes|
|values|A JSON array of String values to run the search over. Case insensitive.|yes|