I'm using ES and I'm running into some issues when trying out the filtering. This is a piece of my document structure:
"id": "36e20ccd-7f96-4611-8891-c9cb1b69957f",
"lang_frameworks": "Language-agnostic",
"category": {
"category_name": "Application Security Testing",
"translations": {
"en": {
"description_what": null,
"description_where": null
}
}
},
"en": {
"title": "Application Security Testing",
"content": "<h2>Int
This is the query I'm using to search through the data:
{
"query": {
"bool": {
"must": [
{
"multi_match": {
"query": "PCI DSS",
"fields": [
...
],
"type": "best_fields",
"operator": "and",
"boost": 1.5
}
}
],
"filter": {
"term": {
"lang_frameworks": "agnostic"
}
}
}
}
}
I want to filter on the language framework part of the data but it is never returning any hits. I have tried a lot of different query structures but it hasn't come back with anything useful.
I also have this part which is a working filter for the categories:
"filter": [{
"nested": {
"path": "category",
"query": {
"bool": {
"should": [
{"match_phrase": {"category.category_name": "PCIE"}}
],
"minimum_should_match": 1
}
}
}
}]