# Is there any "from" in aggregations?

**URL:** <https://discuss.elastic.co/t/is-there-any-from-in-aggregations/33458>\
**Category:** Elasticsearch\
**Created:** [November 1, 2015, 8:18am UTC](https://discuss.elastic.co/t/is-there-any-from-in-aggregations/33458 "2015-11-01T08:18:07Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![Ashish\_Goel](https://avatars.discourse-cdn.com/v4/letter/a/c2a13f/32.png) [@Ashish\_Goel](https://discuss.elastic.co/u/Ashish_Goel)\
**Post date:** [November 1, 2015, 8:18am UTC](https://discuss.elastic.co/t/is-there-any-from-in-aggregations/33458/1 "2015-11-01T08:18:07Z")

</div>

While writing a query, we can mention "from" and "size" to get a specific number of results at a time. By updating "from" we can then get the next set of results. In aggregations, we can mention "size", but I am having a hard time on how to mention "from".

---

<div class="post-metadata">

**Author:** ![dadoonet](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/dadoonet/32/137187_2.png) [@dadoonet](https://discuss.elastic.co/u/dadoonet)\
**Post date:** [November 1, 2015, 9:25am UTC](https://discuss.elastic.co/t/is-there-any-from-in-aggregations/33458/2 "2015-11-01T09:25:03Z")

</div>

I'm not sure you can. Aggregations are built on the full result set, whatever from and size are.

---

<div class="post-metadata">

**Author:** ![Ashish\_Goel](https://avatars.discourse-cdn.com/v4/letter/a/c2a13f/32.png) [@Ashish\_Goel](https://discuss.elastic.co/u/Ashish_Goel)\
**Post date:** [November 1, 2015, 11:21am UTC](https://discuss.elastic.co/t/is-there-any-from-in-aggregations/33458/3 "2015-11-01T11:21:43Z")

</div>

My requirement is to show the results from an aggregation in paginated format. I just want to avoid storing all the results in memory and showing only a few out of them at a time. I fear it will not scale.

---

<div class="post-metadata">

**Author:** ![dadoonet](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/dadoonet/32/137187_2.png) [@dadoonet](https://discuss.elastic.co/u/dadoonet)\
**Post date:** [November 1, 2015, 12:17pm UTC](https://discuss.elastic.co/t/is-there-any-from-in-aggregations/33458/4 "2015-11-01T12:17:36Z")

</div>

I don't understand the use case.  
Not sure you need to complicate something which is working well out of the box. 😛

---

<div class="post-metadata">

**Author:** ![mainec](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/mainec/32/5557_2.png) [@mainec](https://discuss.elastic.co/u/mainec)\
**Post date:** [November 2, 2015, 10:15am UTC](https://discuss.elastic.co/t/is-there-any-from-in-aggregations/33458/5 "2015-11-02T10:15:27Z")

</div>

> [@Ashish\_Goel](#):
>
> My requirement is to show the results from an aggregation in paginated format.

I think the following github issue might be relevant to your question: [https://github.com/elastic/elasticsearch/issues/4915](https://github.com/elastic/elasticsearch/issues/4915)

---

<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 5, 2017, 11:41pm UTC](https://discuss.elastic.co/t/is-there-any-from-in-aggregations/33458/6 "2017-07-05T23:41:19Z")

</div>


