Hello,
I try to search with year of birth a name in elasticsearch but when I try it, it show me total 0.
It's not the first time that my query print total 0
PUT person/delivery/EYYwE2QBbKQAAZyeN3Yb
{
"yearOfBirth": ["1995", "2001"],
"names": ["John", "Phil"],
"dateOfBirth": {
"John": "1995",
"Phil": "2001"
}
}
POST person/deliver/_search
{
"query": {
"range": {
"dateOfBirth": {
"lte": "1995",
"format": "yyyy"
}
}
}
}
and what it print
{
"took": 2,
"timed_out": false,
"_shards": {
"total": 5,
"successful": 5,
"skipped": 0,
"failed": 0
},
"hits": {
"total": 0,
"max_score": null,
"hits": []
}
}
Thank for helping