Reputation: 9121
I have documents containing a tags
array and a city
field. I try to query something like this in ES:
(javascript OR html OR css) AND Los Angeles
Best way to do that?
URI solution?
Upvotes: 1
Views: 153
Reputation: 7762
Here is Elasticsearch query to get (javascript OR html OR css) AND Los Angeles
{
"filter": {
"and": {
"filters": [
{
"term": {
"city": "Los Angeles"
}
},
{
"or": {
"filters": [
{
"terms": {
"tags": ["javascript","html","css"]
}
}
]
}
}
]
}
}
}
Upvotes: 1