# Filter by Count in Datatable

**URL:** <https://discuss.elastic.co/t/filter-by-count-in-datatable/187297>\
**Category:** Kibana\
**Created:** [June 25, 2019, 9:50am UTC](https://discuss.elastic.co/t/filter-by-count-in-datatable/187297 "2019-06-25T09:50:42Z")\
**Posts on this page:** 1\
**Showing post:** 2

<div class="post-metadata">

**Author:** ![nickpeihl](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/nickpeihl/32/112622_2.png) [@nickpeihl](https://discuss.elastic.co/u/nickpeihl)\
**Post date:** [June 26, 2019, 12:39am UTC](https://discuss.elastic.co/t/filter-by-count-in-datatable/187297/2 "2019-06-26T00:39:36Z")

</div>

It's not easily done right now. Here's an answer to a similar question that gives some options.

> [@How to filter visualization based on result of aggregate?](https://discuss.elastic.co/t/how-to-filter-visualization-based-on-result-of-aggregate/126669/3):
>
> hi @Steven_Ensslen, this is similar to a HAVING clause in SQL. Elasticsearch has something called a "bucket selector": [https://www.elastic.co/guide/en/elasticsearch/reference/current/search-aggregations-pipeline-bucket-selector-aggregation.html](https://www.elastic.co/guide/en/elasticsearch/reference/current/search-aggregations-pipeline-bucket-selector-aggregation.html). This is likely what you'd want to use. This functionality is not available in Kibana though. There's an open ER for that: [https://github.com/elastic/kibana/issues/11167](https://github.com/elastic/kibana/issues/11167). If you think that's in-line with what you need, I would go and upvote that ticke…

---

_[View the full topic](https://discuss.elastic.co/t/filter-by-count-in-datatable/187297)._
