# ElasticSearch a filed put to index doesnt show in the index

**URL:** <https://discuss.elastic.co/t/elasticsearch-a-filed-put-to-index-doesnt-show-in-the-index/132972>\
**Category:** Elasticsearch\
**Created:** [May 23, 2018, 10:04am UTC](https://discuss.elastic.co/t/elasticsearch-a-filed-put-to-index-doesnt-show-in-the-index/132972 "2018-05-23T10:04:07Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![uncleBens](https://avatars.discourse-cdn.com/v4/letter/u/a9a28c/32.png) [@uncleBens](https://discuss.elastic.co/u/uncleBens)\
**Post date:** [May 23, 2018, 10:04am UTC](https://discuss.elastic.co/t/elasticsearch-a-filed-put-to-index-doesnt-show-in-the-index/132972/1 "2018-05-23T10:04:07Z")

</div>

I am using the following code to insert new field to existing index. I don't want to reset the indexed data, just to add new field to existing index and old records in index should have null in field colour:

`curl -XPUT 'http://10.10.10.10:9200/myevents/_mapping/event' -d '{ "event" : { "properties" : { "colour":{ "search_analyzer": "search_ngram", "analyzer": "index_ngram", "type": "text" } } }}'`

`{"acknowledged":true}`

Type event has new field colour but indexed elements doesnt.. Do I have to refresh the index somehow?

---

<div class="post-metadata">

**Author:** ![Bernt\_Rostad](https://avatars.discourse-cdn.com/v4/letter/b/3ab097/32.png) [@Bernt\_Rostad](https://discuss.elastic.co/u/Bernt_Rostad)\
**Post date:** [May 23, 2018, 10:37am UTC](https://discuss.elastic.co/t/elasticsearch-a-filed-put-to-index-doesnt-show-in-the-index/132972/2 "2018-05-23T10:37:02Z")

</div>

A change of the mapping will only affect new documents, if you want the old documents in the index to get the new / changed fields you will have to reindex them.

---

<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 20, 2018, 10:37am UTC](https://discuss.elastic.co/t/elasticsearch-a-filed-put-to-index-doesnt-show-in-the-index/132972/3 "2018-06-20T10:37:06Z")

</div>

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