# Facet term integer count overflow

**URL:** <https://discuss.elastic.co/t/facet-term-integer-count-overflow/12396>\
**Category:** Elasticsearch\
**Created:** [June 13, 2013, 12:43pm UTC](https://discuss.elastic.co/t/facet-term-integer-count-overflow/12396 "2013-06-13T12:43:43Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![11118](https://avatars.discourse-cdn.com/v4/letter/1/7993a0/32.png) [@11118](https://discuss.elastic.co/u/11118)\
**Post date:** [June 13, 2013, 12:43pm UTC](https://discuss.elastic.co/t/facet-term-integer-count-overflow/12396/1 "2013-06-13T12:43:43Z")

</div>

Hi  
We got a facet term integer overflow problem.  
We have around 6 billon documents. when i'm faceting, the result count  
value is overflowed like bellow.

## -- afacet: { \_type: terms missing: 0 total: 6679185342 other: 8589934592 terms: [{ term: CISCO\_55 count: -1910749250 }] }

[https://groups.google.com/forum/?fromgroups#!topic/elasticsearch/VFpxNIVkfTQ](https://groups.google.com/forum/?fromgroups#!topic/elasticsearch/VFpxNIVkfTQ)  
I saw this article. but i'm not sure the issue have fixed currently.

Is there something missing?

Thanks

Lee

--  
You received this message because you are subscribed to the Google Groups "elasticsearch" group.  
To unsubscribe from this group and stop receiving emails from it, send an email to [elasticsearch+unsubscribe@googlegroups.com](mailto:elasticsearch+unsubscribe@googlegroups.com).  
For more options, visit [https://groups.google.com/groups/opt\_out](https://groups.google.com/groups/opt_out).

---

<div class="post-metadata">

**Author:** ![Ivan](https://avatars.discourse-cdn.com/v4/letter/i/df788c/32.png) [@Ivan](https://discuss.elastic.co/u/Ivan)\
**Post date:** [June 14, 2013, 5:11pm UTC](https://discuss.elastic.co/t/facet-term-integer-count-overflow/12396/2 "2013-06-14T17:11:36Z")

</div>

To me, it looks like the issue is still there. The aggregater only accepts  
ints as values with no overflow protection.

[https://github.com/elasticsearch/elasticsearch/blob/master/src/main/java/org/elasticsearch/search/facet/terms/strings/InternalStringTermsFacet.java#L179](https://github.com/elasticsearch/elasticsearch/blob/master/src/main/java/org/elasticsearch/search/facet/terms/strings/InternalStringTermsFacet.java#L179)

--  
Ivan

On Thu, Jun 13, 2013 at 5:43 AM, 이해균 [merlinet@gmail.com](mailto:merlinet@gmail.com) wrote:

> Hi  
> We got a facet term integer overflow problem.  
> We have around 6 billon documents. when i'm faceting, the result count  
> value is overflowed like bellow.
> 
> ## -- afacet: { \_type: terms missing: 0 total: 6679185342 other: 8589934592 terms: [{ term: CISCO\_55 count: -1910749250 }] }
> 
> [Redirecting to Google Groups](https://groups.google.com/forum/?fromgroups#!topic/elasticsearch/VFpxNIVkfTQ)  
> I saw this article. but i'm not sure the issue have fixed currently.
> 
> Is there something missing?
> 
> Thanks
> 
> Lee
> 
> --  
> You received this message because you are subscribed to the Google Groups  
> "elasticsearch" group.  
> To unsubscribe from this group and stop receiving emails from it, send an  
> email to [elasticsearch+unsubscribe@googlegroups.com](mailto:elasticsearch+unsubscribe@googlegroups.com).  
> For more options, visit [https://groups.google.com/groups/opt\_out](https://groups.google.com/groups/opt_out).

--  
You received this message because you are subscribed to the Google Groups "elasticsearch" group.  
To unsubscribe from this group and stop receiving emails from it, send an email to [elasticsearch+unsubscribe@googlegroups.com](mailto:elasticsearch+unsubscribe@googlegroups.com).  
For more options, visit [https://groups.google.com/groups/opt\_out](https://groups.google.com/groups/opt_out).

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/elastic/original/3X/1/a/1ac57faf039f6b580b3f104ef42a2a89e41014de.png) [@system](https://discuss.elastic.co/u/system)\
**Post date:** [July 6, 2017, 2:31am UTC](https://discuss.elastic.co/t/facet-term-integer-count-overflow/12396/3 "2017-07-06T02:31:11Z")

</div>


