banbannardMatic NFT
Updated 2022-07-16Copy Reference Fork
99
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
›
⌄
with base as (select *
from polygon.core.dim_labels
where label_type = 'nft'
and (label_subtype = 'token_contract' or label_subtype = 'general_contract')),
base2 as (select
date_trunc('day', b.block_timestamp) as day,
count(distinct(b.tx_hash)) as tx_count,
sum(matic_value) as sales_volume
from polygon.core.fact_event_logs a
join polygon.core.fact_transactions b
on a.tx_hash = b.tx_hash
where contract_address in (select address from base)
and day >= '2022-01-01'
and matic_value > 0
group by 1)
select * from base2
Run a query to Download Data