Created
August 12, 2020 17:19
-
-
Save benwtrent/0e283353fb378d67ee03ea649f03ef26 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
PUT users/_mapping | |
{ | |
"properties": { | |
"geo.location.point": { | |
"type": "geo_point" | |
} | |
} | |
} | |
POST users/_update_by_query | |
{ | |
"script": { | |
"source": "ctx._source.geo.location.point = ctx._source.geo.location.lat + ',' + ctx._source.geo.location.lon", | |
"lang": "painless" | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment