cypherCryptoPunks Sales and Traders - number of punks
Updated 2022-08-31Copy Reference Fork
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
34
35
36
›
⌄
with buys as (select
block_timestamp as buy_time,
buyer_address as address,
price as buy_price,
price_usd as buy_usd,
tokenid as punk
from ethereum.core.ez_nft_sales
where nft_address = '0xb47e3cd837ddf8e4c57f05d70ab865de6e193bbb'
and price > 0
and price_usd > 0
),
sells as (select
block_timestamp as sell_time,
seller_address as address,
price as sell_price,
price_usd as sell_usd,
tokenid as punk
from ethereum.core.ez_nft_sales
where nft_address = '0xb47e3cd837ddf8e4c57f05d70ab865de6e193bbb'
and price > 0
and price_usd > 0
),
sales as (select * from buys
left join sells using (address, punk))
select
address,
count(distinct(punk)) as n_punks,
rank() over (order by n_punks desc) as punks_rank
from sales
where sell_time is null
group by address
Run a query to Download Data