1.显示详细
{
"aggs": {
"price_avg": {
"avg": {
"field": "price"
}
}
}
}
2.仅仅显示想要的
{
"aggs": {
"price_avg": {
"avg": {
"field": "price"
}
}
},
"size": 0
}