Storage or query history. Is it possible to store it temporarily?

Storage or query history. Is it possible to store it temporarily?

I pose the question since I have more than 1 million documents which have categories and locations.

To know how many documents exist in such category or location implement aggregation. but at the same time the aggregation I must paginate them or implement Scroll. In order to be able to return all the buckets.

But when reloading the page or click F5 the aggregation process becomes clear as it should be and returns to perform the calculation.

Is there any way for that aggregation result to be stored in another index temporarily by dates?

Since the aggregations exceeds 200 thousand buckets and the documents to show are only 10.

Any ideas or suggestions?

Thanks and regards. :slight_smile:

Hi,

If you are looking for paginate over your aggregations did you try the composite aggregation:
https://www.elastic.co/guide/en/elasticsearch/reference/7.0/search-aggregations-bucket-composite-aggregation.html#_after

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.