elastic / elasticsearch

Free and Open Source, Distributed, RESTful Search Engine
https://www.elastic.co/products/elasticsearch
Other
1.26k stars 24.86k forks source link

[ES|QL] Sample function #117014

Open dgieselaar opened 3 hours ago

dgieselaar commented 3 hours ago

Description

_search supports a random_sampler aggregation which makes it easy to reduce the result set for heavier aggregations, like categorize_text. A SAMPLE function in ES|QL could serve a similar purpose. Without it, heavy aggregations are hard to use because they need to operate on the full data set.

elasticsearchmachine commented 3 hours ago

Pinging @elastic/es-analytical-engine (Team:Analytics)

sophiec20 commented 2 hours ago

A SAMPLE function will also allow quicker rendering in the UI, giving powerful speedups for example