Moecompare 9
Updated 2023-04-01
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 flow_whale as (
select top 100
buyer,
count(DISTINCT tx_id) as sale_flow_count,
sum(price) as volume
from flow.core.ez_nft_sales
where block_timestamp::date >= '2022-04-21'
group by 1
order by 3 desc
)
, flow as (
select
date_trunc('{{Granularity}}',BLOCK_TIMESTAMP)::date as date,
count(DISTINCT tx_id) as sale_flow_count,
sum(sale_flow_count) over (order by date asc) as cum_sales,
sum(price) as volume
from flow.core.ez_nft_sales
where block_timestamp::date >= '2023-01-01'
and NFT_COLLECTION ilike '%DimensionX'
and buyer in ( select buyer from flow_whale)
group by 1
order by 1
)
select 'DimensionX' as collection, date, sale_flow_count, cum_sales, volume
from flow
)
union all
(
with flow_whale as (
select top 100