TOP N Queries on metric after filtering


I was going through the druid docs on TopN queries:

I want to find out TOP N values of a dimension based on some metric but that metric isn’t ingested into druid.

It will be calculated by applying some filter condition. Is it possible to find out TOP N values based on such a metric ?

Example (from the druid doc): Find out TOP N countries by clicks(which is a metric in druid) where advertiser is and gender is MALE


yes you can use the filters to do that. you can find the filters here: