Skip to content

Instantly share code, notes, and snippets.

@yellow1912
Created June 29, 2014 19:16
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save yellow1912/8d6b6e6ccc03a37eb717 to your computer and use it in GitHub Desktop.
Save yellow1912/8d6b6e6ccc03a37eb717 to your computer and use it in GitHub Desktop.
{
"sort": [
"_score"
],
"query": {
"filtered": {
"query": {
"match_all": "[object] (stdClass: {})"
},
"filter": {
"bool": {
"must": [
{
"term": {
"identifier": "mystore"
}
}
]
}
}
}
},
"aggs": {
"price_stat": {
"stats": {
"field": "price"
}
},
"manufacturer": {
"terms": {
"field": "manufacturer"
}
},
"category": {
"terms": {
"field": "category"
}
},
"options_values": {
"terms": {
"size": 0,
"field": "options_values"
}
}
},
"from": 0,
"size": 10
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment