How to index properties of GeoJson in geo_shape type

(Rohit Nigam) #1

I would like to index the properties in the GeoJson object as a part of geo_shape type in elastic search. Any ideas how to do that. The GeoJson supports the object of type

"type": "Feature",
"geometry": {
"type": "Point",
"coordinates": [125.6, 10.1]
"properties": {
"name": "Dinagat Islands"
while the elastic search supports :--
"location": {
"type": "geo_shape",
"tree": "quadtree",
"precision": "1m"

how do i index the "properties" object given above which has "name" in it as a part of the geo_shape type?


(Russ Cam) #2

Hey @Rohit_Nigam you can create a mapping for a geojson Feature to map

  1. the geometry field as a geo_shape type
  2. the type as a keyword type
  3. the properties as an object type

(system) #3

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.