SniperaxlUSDC vs ATOM vs other stablecoin Swap Metrics
Updated 2022-11-04
99
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
›
⌄
select
Date(date_trunc('week',block_timestamp)) as date,
token_Name,
count(distinct tx_id) as Count_txns,
count(distinct trader) as Count_swappers,
sum(amount) as amount_swapped,
sum(amount_swapped) over (partition by token_Name order by date asc rows between unbounded preceding and current row) as cum_amount_swapped,
avg(amount_swapped) over (partition by token_Name order by date asc rows between unbounded preceding and current row) as avg_amount_swapped,
sum(Count_swappers) over (partition by token_Name order by date asc rows between unbounded preceding and current row) as cum_n_swappers,
sum(Count_txns) over (partition by token_Name order by date asc rows between unbounded preceding and current row) as cum_n_txns
from (
select
v.*,
a.project_name as token_Name,
from_amount/pow(10, from_decimal) as amount
from osmosis.core.fact_swaps v
join osmosis.core.dim_labels a on v.from_currency = a.address
where token_Name in ('DAI.axl','DAI.grv','USDC.axl','USDC.grv','USDT.axl','USDT.grv', 'USTC','ATOM')
and block_timestamp >= '2022-01-01')
group by Date,token_Name
Order By Date,token_Name
Run a query to Download Data