CryptoLionTerra fees n swaps
Updated 2021-08-09
99
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
›
⌄
WITH a as (
SELECT
date_trunc('day',block_timestamp) as day,
sum(offer_amount_usd) as swap_volume,
sum(swap_fee_amount_usd) as swap_fees,
count(tx_id) as swaps
FROM terra.swaps
WHERE block_timestamp >= getdate() - interval '90 days'
AND tx_status = 'SUCCEEDED'
GROUP BY 1
ORDER BY 1 DESC
)
SELECT
day,
swap_fees/swap_volume,
swap_fees,
swap_volume,
swaps,
swap_fees/swaps
FROM a
ORDER BY 1 DESC
Run a query to Download Data