# Geopoint data type not getting updated

**URL:** <https://discuss.elastic.co/t/geopoint-data-type-not-getting-updated/232635>\
**Category:** Logstash\
**Created:** [May 14, 2020, 12:05pm UTC](https://discuss.elastic.co/t/geopoint-data-type-not-getting-updated/232635 "2020-05-14T12:05:48Z")\
**Posts on this page:** 7\
**Page:** 1

<div class="post-metadata">

**Author:** ![shubham184](https://avatars.discourse-cdn.com/v4/letter/s/9d8465/32.png) [@shubham184](https://discuss.elastic.co/u/shubham184)\
**Post date:** [May 14, 2020, 12:05pm UTC](https://discuss.elastic.co/t/geopoint-data-type-not-getting-updated/232635/1 "2020-05-14T12:05:48Z")

</div>

The issue is location is not being shown as **geo\_point** data type so i am not able to use the data in the map section.

Hello there, I have a JSON in below format

```auto
      {
     "id": " ******",
     "key": " ******",
     "value": {
      "rev": " ******"
     },
     "doc": {
      "_id": " ******",
      "_rev": " ******",
      "TxID": " ******",
      "companyID": " ******",
      "companyName": "xxx.",
      "date": "May 12,2020, 12:19:42 PM",
      "email": "xxx@gmail.com",
      "firstName": "Test",
      "ipAddress": "185.221.69.46",
      "lastName": "User5",
      "~version": " ******"
     }
    }

```

Please note the field **ipAddress** , I then use geoip in logstash and it works

```auto
    geoip {
              source => "[doc][ipAddress]"
          }

```

The issue is location is not being shown as **geo\_point** data type so i am not able to use the data in the map section.  
The output in KIbana for the JSON  
 ![image](https://us1.discourse-cdn.com/elastic/original/3X/5/8/5860c14d6ad12067d1c3e15f7d4cbfa5efb599f8.png)

The issue is location is not being shown as **geo\_point** data type so i am not able to use the data in the map section.

**Screenshot from my JSON**

 ![image](https://us1.discourse-cdn.com/elastic/original/3X/2/e/2e3933b874c02ebbb769499f061bef56666015be.png)

Please Note - Kibana Sample data works fine it even shows data type as geo\_point

**Screenshot from Kibana Sample Data below**

 ![image](https://us1.discourse-cdn.com/elastic/original/3X/f/0/f0a5f44c983319e9512d183ed70f32d3a71ba6d5.png)

---

<div class="post-metadata">

**Author:** ![Badger](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/badger/32/25190_2.png) [@Badger](https://discuss.elastic.co/u/Badger)\
**Post date:** [May 14, 2020, 2:40pm UTC](https://discuss.elastic.co/t/geopoint-data-type-not-getting-updated/232635/2 "2020-05-14T14:40:36Z")

</div>

You [need](https://www.elastic.co/guide/en/elasticsearch/reference/current/geo-point.html) an index template that tells elasticsearch that that field is a geo\_point.

---

<div class="post-metadata">

**Author:** ![shubham184](https://avatars.discourse-cdn.com/v4/letter/s/9d8465/32.png) [@shubham184](https://discuss.elastic.co/u/shubham184)\
**Post date:** [May 14, 2020, 6:25pm UTC](https://discuss.elastic.co/t/geopoint-data-type-not-getting-updated/232635/3 "2020-05-14T18:25:49Z")

</div>

I am sorry I do not follow, where do i specify exactly.  
Filter in logstash config or directly in elasticsearch.

---

<div class="post-metadata">

**Author:** ![Badger](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/badger/32/25190_2.png) [@Badger](https://discuss.elastic.co/u/Badger)\
**Post date:** [May 14, 2020, 9:17pm UTC](https://discuss.elastic.co/t/geopoint-data-type-not-getting-updated/232635/4 "2020-05-14T21:17:44Z")

</div>

Personally I would do it in elasticsearch, but you could manage the template using the elasticsearch output if you wanted to.

---

<div class="post-metadata">

**Author:** ![shubham184](https://avatars.discourse-cdn.com/v4/letter/s/9d8465/32.png) [@shubham184](https://discuss.elastic.co/u/shubham184)\
**Post date:** [May 14, 2020, 10:12pm UTC](https://discuss.elastic.co/t/geopoint-data-type-not-getting-updated/232635/5 "2020-05-14T22:12:12Z")

</div>

Could you please guide me how to change it in Elasticsearch, i tried but couldn't.

---

<div class="post-metadata">

**Author:** ![shubham184](https://avatars.discourse-cdn.com/v4/letter/s/9d8465/32.png) [@shubham184](https://discuss.elastic.co/u/shubham184)\
**Post date:** [May 14, 2020, 10:45pm UTC](https://discuss.elastic.co/t/geopoint-data-type-not-getting-updated/232635/6 "2020-05-14T22:45:26Z")

</div>

I just deleted the index and it worked automatically 😷

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/elastic/original/3X/1/a/1ac57faf039f6b580b3f104ef42a2a89e41014de.png) [@system](https://discuss.elastic.co/u/system)\
**Post date:** [June 11, 2020, 10:46pm UTC](https://discuss.elastic.co/t/geopoint-data-type-not-getting-updated/232635/7 "2020-06-11T22:46:44Z")

</div>

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