How to search for utf-8 special characters in elasticsearch? How to search for utf-8 special characters in elasticsearch? elasticsearch elasticsearch

How to search for utf-8 special characters in elasticsearch?


Assuming you're using eg bash, then you have one too many backslashes:

curl -XGET 'http://localhost:9200/index/type/_search?pretty=1' -d '    {"query" : {"text" : { "_all" : "\u0159eky" }}}'{  "took" : 16,  "timed_out" : false,  "_shards" : {    "total" : 5,    "successful" : 5,    "failed" : 0  },  "hits" : {    "total" : 1,    "max_score" : 0.10848885,    "hits" : [ {      "_index" : "index",      "_type" : "type",      "_id" : "1",      "_score" : 0.10848885, "_source" : {"name" : "Vrba u řeky"}    } ]  }}