Fix position-increment-gap doc example
This commit is contained in:
parent
b1965267ec
commit
a77c68ba0e
|
@ -22,7 +22,9 @@ GET /my_index/groups/_search
|
||||||
{
|
{
|
||||||
"query": {
|
"query": {
|
||||||
"match_phrase": {
|
"match_phrase": {
|
||||||
"names": "Abraham Lincoln" <1>
|
"names": {
|
||||||
|
"query": "Abraham Lincoln" <1>
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -31,11 +33,13 @@ GET /my_index/groups/_search
|
||||||
{
|
{
|
||||||
"query": {
|
"query": {
|
||||||
"match_phrase": {
|
"match_phrase": {
|
||||||
"names": "Abraham Lincoln",
|
"names": {
|
||||||
|
"query": "Abraham Lincoln",
|
||||||
"slop": 101 <2>
|
"slop": 101 <2>
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
--------------------------------------------------
|
--------------------------------------------------
|
||||||
// AUTOSENSE
|
// AUTOSENSE
|
||||||
<1> This phrase query doesn't match our document which is totally expected.
|
<1> This phrase query doesn't match our document which is totally expected.
|
||||||
|
@ -50,7 +54,7 @@ The `position_increment_gap` can be specified in the mapping. For instance:
|
||||||
PUT my_index
|
PUT my_index
|
||||||
{
|
{
|
||||||
"mappings": {
|
"mappings": {
|
||||||
"my_type": {
|
"groups": {
|
||||||
"properties": {
|
"properties": {
|
||||||
"names": {
|
"names": {
|
||||||
"type": "string",
|
"type": "string",
|
||||||
|
|
Loading…
Reference in New Issue