WARNING: Version 2.1 of Elasticsearch has passed its EOL date.
This documentation is no longer being maintained and may be removed. If you are running this version, we strongly advise you to upgrade. For the latest information, see the current release documentation.
index
editindex
editThe index
option controls how field values are indexed and, thus, how they
are searchable. It accepts three values:
|
Do not add this field value to the index. With this setting, the field will not be queryable. |
|
Add the field value to the index unchanged, as a single term. This is the
default for all fields that support this option except for
|
|
This option applies only to |
For example, you can create a not_analyzed
string field with the following:
PUT /my_index { "mappings": { "my_type": { "properties": { "status_code": { "type": "string", "index": "not_analyzed" } } } } }