cheeyoung-kekCryptopunk Sales and Traders 3
Updated 2022-08-31
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
sales as(
select
date_trunc('day', block_timestamp) as day,
price as price_eth,
price_usd,
tx_hash
from ethereum.core.ez_nft_sales
where project_name = 'cryptopunks'
and block_timestamp >= current_date() - interval '3 months'
and event_type = 'sale'
and buyer_address != '0x0000000000000000000000000000000000000000'
and nft_address in ('0xb47e3cd837ddf8e4c57f05d70ab865de6e193bbb', '0xb7f7f6c52f2e2fdb1963eab30438024864c313f6')
and currency_symbol = 'ETH'
and price >0 and price_usd >0
),
raw as(
select
day,
count(DISTINCT tx_hash) as tx_count,
sum(price_eth) as eth,
sum(price_usd) as USD,
sum(tx_count) over (order by day) as cum_sales,
sum(USD) over (order by day) as cum_sales_usd
from sales
group by 1
)
select * from raw
Run a query to Download Data