amir007-Q63RX1Osmosis - Daily Active User - Osmo LPers
Updated 2022-10-19
99
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
›
⌄
with osmo_pool as
(
select date_trunc('day', block_timestamp::date) as date
, sum(case when action = 'pool_joined' then amount/1e6 else 0 end) as pool_joined
, sum(case when action = 'pool_exited' then amount/1e6 else 0 end) as pool_exited
, sum(case when action = 'pool_joined' then amount/1e6 else 0 end)
- sum(case when action = 'pool_exited' then amount/1e6 else 0 end) as pool
from osmosis.core.fact_liquidity_provider_actions
where block_timestamp::date > current_date - {{PastDays}}
and currency = 'uosmo'
group by 1
)
select date as "Date"
, sum(pool_joined) over (order by date) as "pool joined Osmo"
, sum(pool_exited) over (order by date) as "pool exited Osmo"
, sum(pool) over (order by date) as "pool Osmo"
from osmo_pool
order by 1
Run a query to Download Data