I don't have a Lucene background, so this may be rudimentary.
The index types are defined here with an explanation:
Indexed, Searchable, Tokenized
Indexed, Searchable, Not Tokenized
Not Indexed, Not Searchable, Not Tokenized
The first option (analyzed) and the last (no) seem to make a lot of sense,
and I understand them.
However, I do struggle to come up with a use case where not_analyzed should
be used. Since it is not tokenized, I would expect a match only when the
exact same search term is provided in a query. In fact, since it is not
tokenized, it has to match right down to stop words, whitespace and case,
correct? Maybe for matching on a hash code, a case-insensitive username, or
a zip code?
If I have a not_analyzed field containing "XY&Z Company", will I only get a
match if I query for "XY&Z Company"?