Keyword type to lowercase

Normalizer for Keyword datatype is Experimental currently.

https://www.elastic.co/guide/en/elasticsearch/reference/current/keyword.html#keyword-params

Is there another way to lowercasing value of keyword field?

this is mapping

properties : {
  "country" : {
    "type":"keyword"
  }
}

Add documents

POST  {
  "country":"US"
}
POST  {
  "country":"us"
}

Now, want to search both US and us.
this expected to return two document above.

GET
search?q=country:us

How can I do that without using experimental feature?

You can use ingest node and lowercase your field at index time.

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