Arkannstaking 6
Updated 2023-01-20Copy Reference Fork
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
31
32
33
34
35
36
›
⌄
with
Unstakers_Table as (
select
tx_caller_address as Unstakers_User,
count (distinct tx_id) as Unstake_Actions
from
osmosis.core.fact_staking
where
tx_succeeded = 'TRUE'
and currency = 'uosmo'
and action = 'undelegate'
group by 1
),
LPers_Table as (
select
liquidity_provider_address as LPer_User,
count(distinct tx_id) as LPs_Actions
from
osmosis.core.fact_liquidity_provider_actions
where
tx_succeeded = 'TRUE'
and currency = 'uosmo'
and action = 'pool_joined'
and liquidity_provider_address in (select Unstakers_User from Unstakers_Table)
group by 1
),
ReDelegators_Table as (
select
tx_caller_address as Redelegator_User,
count (distinct tx_id) as Redelegate_Actions
from
osmosis.core.fact_staking
where
tx_succeeded = 'TRUE'
and currency = 'uosmo'
and action = 'redelegate'
Run a query to Download Data