I am trying to get items from my index with empty email.
If i search for items with email:"" i get 0 results
"query": {
"term": {
"email": ""
}
}
{
"took" : 1,
"timed_out" : false,
"_shards" : {
"total" : 1,
"successful" : 1,
"skipped" : 0,
"failed" : 0
},
"hits" : {
"total" : {
"value" : 0,
"relation" : "eq"
},
"max_score" : null,
"hits" : [ ]
}
}
if i make a query like:
{
"query": {
"term": {
"id": "1234"
}
}
}
i get an item with email:""
"_source" : {
"id" : "1234",
"email" : "",
}
My mappings look like so:
{
"mappings": {
"_doc": {
"dynamic": "false",
"properties": {
"email": {
"type": "text",
"analyzer": "email_analyzer"
},
"id": {
"type": "keyword"
}
}
}
}
}
What can be the cause for this ?