|
The current default query for $search is
/**
|
* search: Analyzed search.
|
* term: Unanalyzed search.
|
* compound: Combines ops.
|
* span: Find in text field regions.
|
* exists: Test for presence of a field.
|
* near: Find near number or date.
|
* range: Find in numeric or date range.
|
*/
|
{
|
search: {
|
query: 'string'
|
path: 'string'
|
}
|
}
|
the search: operator has been deprecated. It should be replaced with text:
/**
|
* text: Analyzed search.
|
* term: Unanalyzed search.
|
* compound: Combines ops.
|
* span: Find in text field regions.
|
* exists: Test for presence of a field.
|
* near: Find near number or date.
|
* range: Find in numeric or date range.
|
*/
|
{
|
text: {
|
query: 'string',
|
path: 'string'
|
}
|
}
|
It's also missing a comma between the query option and the path option, which could be confusing.
|