/
Popular labels

Popular labels

Description:


Popular labels



Impala Query:


select regexp_extract(qname, '([a-zA-Z0-9-_]*)\..*\.nl.',1) as reg, sum(counter) as totals
from (select qname, count(*) as counter
from dns.staging
group by qname
) as tmp
group by reg
order by totals desc




Example Output:


reg totals
1 www 84461395
2 ns1 36675995
3 ns2 27533162
4 ns3 11323477
5 mail 9522727
6 ns 5325755
7 ns4 3612355
8 ns5 3393783
9 ns01 2720515
10 _dmarc 2631726