Switch to keyword/text type, add refresh parameter
This commit is contained in:
parent
48ea9137da
commit
8016a2f951
|
@ -16,12 +16,10 @@ PUT /my_index
|
||||||
"properties": {
|
"properties": {
|
||||||
"post_date": { "type": "date" },
|
"post_date": { "type": "date" },
|
||||||
"user": {
|
"user": {
|
||||||
"type": "string",
|
"type": "keyword"
|
||||||
"fielddata": "true"
|
|
||||||
},
|
},
|
||||||
"name": {
|
"name": {
|
||||||
"type": "string",
|
"type": "keyword"
|
||||||
"fielddata": "true"
|
|
||||||
},
|
},
|
||||||
"age": { "type": "integer" }
|
"age": { "type": "integer" }
|
||||||
}
|
}
|
||||||
|
@ -94,7 +92,7 @@ the average price per document.
|
||||||
|
|
||||||
[source,js]
|
[source,js]
|
||||||
--------------------------------------------------
|
--------------------------------------------------
|
||||||
PUT /my_index/my_type/1
|
PUT /my_index/my_type/1?refresh
|
||||||
{
|
{
|
||||||
"product": "chocolate",
|
"product": "chocolate",
|
||||||
"price": [20, 4]
|
"price": [20, 4]
|
||||||
|
|
Loading…
Reference in New Issue