# Index : no VS Index: not\_analyzed

**URL:** <https://discuss.elastic.co/t/index-no-vs-index-not-analyzed/58287>\
**Category:** Elasticsearch\
**Created:** [August 17, 2016, 7:08pm UTC](https://discuss.elastic.co/t/index-no-vs-index-not-analyzed/58287 "2016-08-17T19:08:17Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![sombilat](https://avatars.discourse-cdn.com/v4/letter/s/779978/32.png) [@sombilat](https://discuss.elastic.co/u/sombilat)\
**Post date:** [August 17, 2016, 7:08pm UTC](https://discuss.elastic.co/t/index-no-vs-index-not-analyzed/58287/1 "2016-08-17T19:08:17Z")

</div>

Hello,

I have encountered an issue in Logstash. Currently I am using LS, 2.0.0.

Now, in my mapping. Previously I have a field:

```
"content" : {
                   "type" : "string",
                   "index" : "not_analyzed"
                 },

```

I output data there that will exceed the container of 32,766 bytes.

It throws the error of:

> "reason" =\> "Document contains at least 1 immense term in field="content" (whose UTF8..."

I found this in stackoverflow: [elasticsearch - UTF8 encoding is longer than the max length 32766 - Stack Overflow](http://stackoverflow.com/questions/24019868/utf8-encoding-is-longer-than-the-max-length-32766)

So to make this work, I have to do this:

```
        "content" : {
                           "type" : "string",
                           "index" : "no"
                         },

```

It fixes the issue. Based on that overflow thread, it says that it still makes the field of content not "filterable" or searchable.

I wanted to discuss on why did it fix the issue? I found no source material (or I did not see it) in elasticsearch doucmentation. Could anyone explain to me the pro's of using "index" : "no" against "index" : "not\_analyzed"?

I plan to use the "index" : "no", in my mapping so that I can fix the issue. I just want to know why it worked and what are its pros and cons.

Thanks,

---

<div class="post-metadata">

**Author:** ![warkolm](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/warkolm/32/39224_2.png) [@warkolm](https://discuss.elastic.co/u/warkolm)\
**Post date:** [August 17, 2016, 7:33pm UTC](https://discuss.elastic.co/t/index-no-vs-index-not-analyzed/58287/2 "2016-08-17T19:33:50Z")

</div>

Have a read of [https://www.elastic.co/guide/en/elasticsearch/reference/2.3/mapping-index.html](https://www.elastic.co/guide/en/elasticsearch/reference/2.3/mapping-index.html)

---

<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:** [July 5, 2017, 10:27pm UTC](https://discuss.elastic.co/t/index-no-vs-index-not-analyzed/58287/3 "2017-07-05T22:27:10Z")

</div>


