All (non-redundant) values of a list of fields

Hello,

I would like to know which Elastic query can give me all (non-redundant) values ​​of a list of fields.

For example, I would like to know all the possible values ​​contained in field: User, SubjectUser, UserName?

(I found how to do it on Splunk but not with Elastic: - /)

Thank you very much for your help,

Florent

Hi Florent_Fauvin

If the fields are of type keyword you can use a terms aggregation for this purpose. Please, take a look at the documentation here: https://www.elastic.co/guide/en/elasticsearch/reference/current/search-aggregations-bucket-terms-aggregation.html

Best regards
Flemming G. Jensen

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