# Not able to search the data in index

**URL:** <https://discuss.elastic.co/t/not-able-to-search-the-data-in-index/91734>\
**Category:** Elasticsearch\
**Created:** [July 4, 2017, 8:23am UTC](https://discuss.elastic.co/t/not-able-to-search-the-data-in-index/91734 "2017-07-04T08:23:07Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![kartikeya\_sharma\_13](https://avatars.discourse-cdn.com/v4/letter/k/c77e96/32.png) [@kartikeya\_sharma\_13](https://discuss.elastic.co/u/kartikeya_sharma_13)\
**Post date:** [July 4, 2017, 8:23am UTC](https://discuss.elastic.co/t/not-able-to-search-the-data-in-index/91734/1 "2017-07-04T08:23:07Z")

</div>

Hi ,

I am fetching the data from database through logstash jdbc plugin and ingesting it into Elasticsearch .

When i am querying the data through Kibana or REST from Elasticsearch , i am getting the error as follows

> Discover: Fielddata is disabled on text fields by default. Set fielddata=true on [type] in order to load fielddata in memory by uninverting the inverted index. Note that this can however use significant memory. Alternatively use a keyword field instead.

I tried by setting the fielddata=true for the field "type" in the index . But i am not able to figure out the issue .  
Any lead on this issue .

Thanks

---

<div class="post-metadata">

**Author:** ![medcl.net](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/medcl.net/32/4414_2.png) [@medcl.net](https://discuss.elastic.co/u/medcl.net)\
**Post date:** [July 4, 2017, 9:28am UTC](https://discuss.elastic.co/t/not-able-to-search-the-data-in-index/91734/2 "2017-07-04T09:28:47Z")

</div>

> [@kartikeya\_sharma\_13](#):
>
> Fielddata is disabled on text fields by default.

Hi, @kartikeya_sharma_13 ,  
You should customize your mapping before actually ingest the data, if this field you don't need to analyze it, you may set the type to `keyword`

Medcl

---

<div class="post-metadata">

**Author:** ![medcl.net](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/medcl.net/32/4414_2.png) [@medcl.net](https://discuss.elastic.co/u/medcl.net)\
**Post date:** [July 4, 2017, 9:33am UTC](https://discuss.elastic.co/t/not-able-to-search-the-data-in-index/91734/3 "2017-07-04T09:33:47Z")

</div>

also remember to refresh the index pattern, if you already updated the mapping to enable fielddata, 🙂

---

<div class="post-metadata">

**Author:** ![kartikeya\_sharma\_13](https://avatars.discourse-cdn.com/v4/letter/k/c77e96/32.png) [@kartikeya\_sharma\_13](https://discuss.elastic.co/u/kartikeya_sharma_13)\
**Post date:** [July 4, 2017, 3:00pm UTC](https://discuss.elastic.co/t/not-able-to-search-the-data-in-index/91734/4 "2017-07-04T15:00:11Z")

</div>

Thanks for the input . I refreshed the index pattern in Kibana . Now its working . And yes it being mapped to type keyword.  
Thank for the help @medcl.net

---

<div class="post-metadata">

**Author:** ![medcl.net](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/medcl.net/32/4414_2.png) [@medcl.net](https://discuss.elastic.co/u/medcl.net)\
**Post date:** [July 5, 2017, 5:17am UTC](https://discuss.elastic.co/t/not-able-to-search-the-data-in-index/91734/5 "2017-07-05T05:17:21Z")

</div>

you are welcome!

---

<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:** [November 4, 2022, 4:51am UTC](https://discuss.elastic.co/t/not-able-to-search-the-data-in-index/91734/8 "2022-11-04T04:51:34Z")

</div>


