CryptoLionUNI Gas Fees
Updated 2021-05-27
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
›
⌄
SELECT
date_trunc('day',uniswapv3.swaps.block_timestamp) as day,
count(uniswapv3.swaps.tx_id) as actions,
avg(ethereum.transactions.fee_usd) as avg_fees,
sum(ethereum.transactions.fee_usd) as total_fees,
CASE
WHEN actions IS NULL THEN ''
ELSE 'swaps'
END as type_
FROM uniswapv3.swaps
INNER JOIN ethereum.transactions on uniswapv3.swaps.tx_id = ethereum.transactions.tx_id
WHERE
uniswapv3.swaps.block_timestamp >= getdate() - interval '30 days'
GROUP by 1
UNION
SELECT
date_trunc('day',uniswapv3.lp_actions.block_timestamp) as day,
count(uniswapv3.lp_actions.tx_id) as actions,
avg(ethereum.transactions.fee_usd) as avg_fees,
sum(ethereum.transactions.fee_usd) as total_fees,
CASE
WHEN actions IS NULL THEN ''
ELSE 'lp_actions'
END as type_
FROM uniswapv3.lp_actions
INNER JOIN ethereum.transactions on uniswapv3.lp_actions.tx_id = ethereum.transactions.tx_id
WHERE
uniswapv3.lp_actions.block_timestamp >= getdate() - interval '30 days'
GROUP by 1
ORDER BY 1
Run a query to Download Data