SniperTop 10 DAO by number of transactions copy
Updated 2023-03-28
99
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
›
⌄
with
tbl1 AS (
select tx_hash,y.project_name
from arbitrum.core.fact_event_logs x
join arbitrum.core.dim_labels y on x.contract_address=y.address)
SELECT project_name,
count(DISTINCT t1.tx_hash) AS total_transactions,
count(DISTINCT from_address) AS total_users,
(total_transactions/ total_users) AS avg_txs_per_user,
sum(tx_fee) AS total_eth_fees,
sum(gas_used) AS total_gas,
(total_eth_fees / total_users) AS avg_eth_fee_user,
(total_eth_fees / total_transactions) AS avg_tx_fee
-- row_number() over (order by total_users DESC) as row_number
FROM tbl1 t1
LEFT OUTER JOIN arbitrum.core.fact_transactions t2 on t1.tx_hash = t2.tx_hash
WHERE status = 'SUCCESS'
GROUP BY 1
HAVING avg_txs_per_user > 5
-- ORDER BY row_number ASC
LIMIT 10
Run a query to Download Data