boomer77steth - eth swaps
Updated 2022-06-12
99
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
›
⌄
with swaps as (select *
from ethereum.core.ez_dex_swaps
where symbol_out = 'stETH' and year(block_timestamp) = '2022'),
swap_to_eth as (select *
from ethereum.core.ez_dex_swaps
where symbol_in = 'stETH' and year(block_timestamp) = '2022'),
swap1 as (select date(block_timestamp) as dt, sum(amount_in) as eth_to_stETH, sum(amount_in_usd) as eth_to_stETH_usd
from swaps
group by 1),
swap2 as (select date(block_timestamp) as dt, sum(amount_in) as stETH_to_eth, sum(amount_in_usd) as stETH_to_eth_usd
from swap_to_eth
group by 1)
select a.dt, a.ETH_to_stETH, b.stETH_to_ETH, a.eth_to_stETH_usd, b.stETH_to_eth_usd
from swap1 a
left join swap2 b on a.dt = b.dt
Run a query to Download Data