druid icon indicating copy to clipboard operation
druid copied to clipboard

Query like collect_list and collect_set support

Open xueyumusic opened this issue 7 years ago • 2 comments

When doing data statistic and anlysis, it often uses query like concat_ws(',',collect_list(coupon_id)) after groupby. Could collect_list and collect_set be an appropriate query in druid? I found it looks a bit hard when implement collect_list as a kind of Aggregator. When implementing BufferedAggregator it does not have fixed bytebuf length and MaxIntermediateSize...

xueyumusic avatar Jun 14 '19 13:06 xueyumusic

As a workround, you can implement BufferedAggregator on heap. I have done a BufferedAggregator on heap.

extensions-contrib/unique/src/main/java/org/apache/druid/query/aggregation/unique/UniqueBufferAggregator.java https://github.com/apache/incubator-druid/pull/7594

pzhdfy avatar Aug 28 '19 02:08 pzhdfy

This issue has been marked as stale due to 280 days of inactivity. It will be closed in 4 weeks if no further activity occurs. If this issue is still relevant, please simply write any comment. Even if closed, you can still revive the issue at any time or discuss it on the [email protected] list. Thank you for your contributions.

stale[bot] avatar Jun 03 '20 03:06 stale[bot]