How do I get unique keys counts, not unique values per key?

I have a collections of documents.
What query can produce unique keys counts (for a time interval), not unique values per key?
It might be too simple to do and not mentioned anywhere... thus I cannot find it?

There are Elasticsearch APIs that give you info about the fields themselves, such as the mapping API and field caps API. These APIs provide metadata to help applications like Kibana work, and aren't meant for analysis that can be done in Kibana.

You probably want to have a transform to retrieve information from your index, transform it into statistics, and store it in another index. See Transforming data | Elasticsearch Guide [8.8] | Elastic

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