1 klakekent OP 我想得到的结果大概就是 1 2 ××× 4 2 3 ××× 1 |
![]() | 2 zhangfeiwudi 2018-03-30 17:00:33 +08:00 group on + order by 可行否? |
3 klakekent OP 我发现用 aggs 和 top_hits 组合会有个问题,就是比如我的 postid 有 6 条评论,但是通过这个方式选出来显示 total 数量不足 6 条 |
![]() | 4 turan12 2018-03-30 22:31:50 +08:00 max(stars) + group by postid |
5 Hieast 2018-03-31 01:41:55 +08:00 via Android 使用 terms postid 桶,每个桶里取 max starts |
6 klakekent OP 解决 用 collapse 很简单 |