<>1. summary

Each document has one _id The index that uniquely identifies it , The index is indexed , So that it can be used GET API or ids query Find documents .

If not specified ,es One is also generated by default id character string .

_id Queries are often used in the following queries :term, terms,match,query_string,simple_query_string

<>2. Examples

Mapping Definition and insertion
PUT example PUT example/docs/_mapping { "properties":{ "cityId":{"type":
"long"}, "cityName":{"type": "text"}, "location":{"type": "geo_point"},
"remark":{"type": "text"} } } PUT example/docs/1 { "cityId":1,
"cityName":"xi'an", "location": { "lat":"34.45", "lon":"107.40" },
"remark":" Tourist cities in China " } PUT example/docs/2 { "cityId":2, "cityName":"Singapore",
"location": "1.05,104.60", "remark":" World ports " } PUT example/docs/3 { "cityId":3,
"cityName":"Sydney", "location": [151.12, -33.51], "remark":" Big city of Australia " }
query
# query id by 1 and 2 Document for GET example/docs/_search { "query": { "terms": { "_id": [1, 2] }
} }

Technology
©2019-2020 Toolsou All rights reserved,
python obtain excel A column or row of data ( Essence )2020 year 7 month 12 day webpack Use of common plug-ins python in switch_to_alert Usage of SpringBoot JpaRepository Database addition, deletion, modification and query Shortest path Dijkstra (Python3)[work] python read txt Last line of file ( Essence )2020 year 6 month 26 day C# Class library GUID Help class vue Value transfer between parent-child and non parent-child components 【Python- data fetch 】 read txt Each line of file generates a list of data python primitive -- lock Lock