December 2017
Intermediate to advanced
434 pages
10h 29m
English
Elasticsearch supports querying both structured data and full text. While full-text queries need scoring mechanisms to find the best matching documents, structured searches don't need scoring. The constant score query allows us to convert a scoring query which normally runs in query context to a non-scoring filter context. The constant score query is a very important tool in your toolbox.
For example, the term query is normally run in a query context. That means when Elasticsearch executes a term query, it not only filters the documents but also scores all of them:
GET /amazon_products/products/_search{ "query": { "term": { "manufacturer.raw": "victory multimedia" } }}
Notice the highlighted part, the bold text. This ...
Read now
Unlock full access