# I want to get the exact distinct count and the docs in query

**URL:** <https://discuss.elastic.co/t/i-want-to-get-the-exact-distinct-count-and-the-docs-in-query/246330>\
**Category:** Elasticsearch\
**Created:** [August 25, 2020, 5:04pm UTC](https://discuss.elastic.co/t/i-want-to-get-the-exact-distinct-count-and-the-docs-in-query/246330 "2020-08-25T17:04:39Z")\
**Posts on this page:** 1\
**Showing post:** 4

<div class="post-metadata">

**Author:** ![Christian\_Dahlqvist](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/christian_dahlqvist/32/4617_2.png) [@Christian\_Dahlqvist](https://discuss.elastic.co/u/Christian_Dahlqvist)\
**Post date:** [August 26, 2020, 6:19am UTC](https://discuss.elastic.co/t/i-want-to-get-the-exact-distinct-count-and-the-docs-in-query/246330/4 "2020-08-26T06:19:05Z")

</div>

Cardinality aggregations in Elasticsearch are always an approximation. Have a look at [this thread](https://discuss.elastic.co/t/is-it-true-that-sometimes-elasticsearch-aggregations-can-be-inaccurate/156396/2) for discussion on the topic.

---

_[View the full topic](https://discuss.elastic.co/t/i-want-to-get-the-exact-distinct-count-and-the-docs-in-query/246330)._
