Commit 212504b4ea2e5ffefe0776a8df38c8b0306bdf37
1 parent
3f0a1352
Exists in
master
and in
21 other branches
Example of facets
Showing
1 changed file
with
4 additions
and
0 deletions
Show diff stats
README.md
... | ... | @@ -264,6 +264,10 @@ products.suggestions # ["peanut butter"] |
264 | 264 | |
265 | 265 | ### Facets |
266 | 266 | |
267 | +[Facets](http://www.elasticsearch.org/guide/reference/api/search/facets/) provide aggregated search data. | |
268 | + | |
269 | + | |
270 | + | |
267 | 271 | ```ruby |
268 | 272 | products = Product.search "2% Milk", facets: [:store_id, :aisle_id] |
269 | 273 | p products.facets | ... | ... |