binhachon11. [Easy] Claims vs Price - Histogram - before 6 months
Updated 2021-12-24
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
27
28
29
30
31
32
33
›
⌄
with ens_registration as(
select
distinct origin_address as address
from
ethereum.udm_events
where contract_address = '0x283af0b28c62c092c9727f1ee09c02ca627eb7f5'
and origin_function_name ilike '%register%'
and block_timestamp < getdate() - interval'6 months'
),
transactions_count as (
select
origin_address,
count(distinct tx_id) as number_of_transactions
from
ethereum.udm_events
where origin_address in (select address from ens_registration)
group by origin_address
)
select
rounded_transactions,
number_of_addresses,
sum(number_of_addresses) over (order by rounded_transactions) * 100 / sum(number_of_addresses) over () as percentile
from (
select
round(number_of_transactions,-1) as rounded_transactions,
count(number_of_transactions) as number_of_addresses
from
transactions_count
group by rounded_transactions
)
order by rounded_transactions
limit 20
Run a query to Download Data