Query editor
WITH cex_wallets AS (SELECTaddress,ARBITRARY(name) AS label,'exchange' AS categoryFROM labels.addressesWHERE blockchain = 'ethereum'AND lower(category) = 'institution'GROUP BY address),activity AS (SELECTt."from" AS address,COUNT(DISTINCT t.tx_hash) AS tx_count_48h,COUNT(DISTINCT t."to") AS unique_receivers,COALESCE(SUM(t.amount_usd), 0) AS usd_volume_48h,MAX(t.block_time) AS last_seenFROM tokens.transfers tWHERE t.blockchain = 'ethereum'AND t.block_time >= NOW() - INTERVAL '48' HOURAND t."from" IN (SELECT address FROM cex_wallets)GROUP BY 1HAVING COUNT(DISTINCT t.tx_hash) >= 5)SELECTcast(a.address AS varchar) AS address,c.label,c.category,a.tx_count_48h,a.unique_receivers,a.usd_volume_48h,a.last_seen,CASEWHEN a.tx_count_48h >= 5000 THEN 'volcanic'WHEN a.tx_count_48h >= 1000 THEN 'hot'WHEN a.tx_count_48h >= 100 THEN 'active'WHEN a.tx_count_48h > 0 THEN 'quiet'ELSE 'dormant'END AS activity_tierFROM activity aJOIN cex_wallets c ON c.address = a.addressORDER BY a.tx_count_48h DESCLIMIT 20