Hi, I'm a new Elasticsearch user (v1.7). I have an index who look like this :
// house with occuped planning
{
"id": "54",
"city": "foo",
"planning": [
{
"id": 839,
"start": "2018-02-10T16:00:00+00:00",
"end": "2018-02-17T10:00:00+00:00"
},
{
"id": 833,
"start": "2018-02-22T16:00:00+00:00",
"end": "2018-02-29T10:00:00+00:00"
}
]
}
I want to find a way for get houses in city "foo" which have no occuped planning in a range between (or overlap) two dates.
POST /index/house/_search
{
"query": {
"bool": {
"must": [
{
"term": {
"city": "foo"
}
}
]
}
}
}
I dont find what kind of query/nested/filter (?) have I to add