LTirrell2022-02-25_terra_burn-by-currency
Updated 2022-03-01
99
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
›
⌄
select
date_trunc('day', block_timestamp) as datetime,
ask_currency,
sum(offer_amount) as amount_luna,
sum(offer_amount_usd) as amount_usd,
sum(amount_luna) over (order by datetime asc rows between unbounded preceding and current row) as cumulative_luna,
sum(amount_usd) over (order by datetime asc rows between unbounded preceding and current row) as cumulative_usd
from
terra.swaps
where
datetime >= current_date - 31
and datetime <= current_date - 1
and offer_currency = 'LUNA'
and tx_status = 'SUCCEEDED'
group by
datetime,
ask_currency
Run a query to Download Data