Reputation: 426
Just need to understand how do we filter for analyzed fields in elastic search indexes?
Upvotes: 0
Views: 108
Reputation: 19514
Elastic search use inverted index for analyzed data, so keep in mind when you do query. Also it always depends on tokenizer. For instance standart take text "hello world" will be saved as "hello", "world", meanwhile ngGram split "FC Schalke 04" to FC, Sc, Sch, ch, cha, ha, hal, al, alk, lk, lke, ke, 04. So analyzed fields really matter how you configure them in mapping, then depends on that you can write search queries
Upvotes: 1
Reputation: 1182
I am guessing the document is already indexed as it is analyzed. You can filter while querying that field in the document.
Refer the following document to see how to apply filters with querying.
https://www.elastic.co/guide/en/elasticsearch/reference/1.6/query-dsl-filters.html
Upvotes: 1