mariyaTotal Number of Buyers (base on collections nimber)
Updated 2022-11-12
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
›
⌄
with top_10 as ( select nft_address , sum(price_usd) as volume
from ethereum.core.ez_nft_sales
where price_usd is not null and block_timestamp::date >= CURRENT_DATE - 180
group by 1
order by 2 desc
limit 11)
, fnl as ( select buyer_address, count(DISTINCT(project_name)) as total
from ethereum.core.ez_nft_sales a join ethereum.core.dim_labels b on a.nft_address = b.address
where nft_address in ( select nft_address from top_10)
and block_timestamp::date >= CURRENT_DATE - 180
and project_name is not null
group by 1)
select count(DISTINCT(buyer_address)) as totals,
case when total = 1 then '1 Collection'
when total = 2 then '2 Collections'
when total = 3 then '3 Collections'
when total = 4 then '4 Collections'
when total = 5 then '5 Collections'
when total = 6 then '6 Collections'
when total = 7 then '7 Collections'
when total = 8 then '8 Collections'
when total = 9 then '9 Collections'
when total = 10 then '10 Collections' end as type from fnl
group by 2
Run a query to Download Data