# Problem with nested facets

**URL:** <https://discuss.elastic.co/t/problem-with-nested-facets/8115>\
**Category:** Elasticsearch\
**Created:** [June 15, 2012, 9:33am UTC](https://discuss.elastic.co/t/problem-with-nested-facets/8115 "2012-06-15T09:33:47Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![Rauan\_Maemirov](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/rauan_maemirov/32/826_2.png) [@Rauan\_Maemirov](https://discuss.elastic.co/u/Rauan_Maemirov)\
**Post date:** [June 15, 2012, 9:33am UTC](https://discuss.elastic.co/t/problem-with-nested-facets/8115/1 "2012-06-15T09:33:47Z")

</div>

Here's my mapping scheme: [https://gist.github.com/36a98871a2292556d2f7](https://gist.github.com/36a98871a2292556d2f7)  
If I drop 'sellers' nested type doc, nested facet at the end of script  
works correctly, otherwise it shows wrong numbers for sum by field value.

Is it allowed to put multiple nested doc types in one doc?

---

<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, 3:23am UTC](https://discuss.elastic.co/t/problem-with-nested-facets/8115/2 "2017-07-06T03:23:58Z")

</div>


