RamaharVelodrome TVL
Updated 2023-07-15
99
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
›
⌄
With T1 as (select
block_timestamp,
pool_name,
lp_action,
coalesce(token0_amount_usd, 0) + coalesce(token1_amount_usd,0) as totalUSD_value
from optimism.velodrome.ez_lp_actions )
select
DATE(block_timestamp) as dayz,
pool_name,
sum(iff (lp_action = 'deposit', totalUSD_value, 0)) as deposit_value,
- sum(iff (lp_action = 'withdraw', totalUSD_value, 0)) as withdrawal_value,
coalesce(deposit_value, 0) + coalesce(withdrawal_value, 0) as net_value,
sum(net_value) over (partition by pool_name order by dayz asc rows between unbounded preceding and current row) as cumulative_TVL
from T1
group by 1, 2
Run a query to Download Data