Popex404#1 Sei Stake growth
Updated 2023-10-29
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
›
⌄
With cte as (
SELECT Month as "Week",
case
when Previous_Month<1 then Null else
((Monthly_Transactions/Previous_Month)-1) *100 end as "WoW Growth Rates", Monthly_Transactions as "Weekly Transactions"
FROM(
SELECT
date_trunc('week', block_timestamp) as Month
,COUNT(DISTINCT tx_id) as Monthly_Transactions
,lag(Monthly_Transactions) OVER (ORDER BY Month) as Previous_Month
FROM sei.gov.fact_staking
where block_timestamp >= '2023-08-15'
GROUP BY Month
ORDER BY Month ASC
)
)
select
case
when "WoW Growth Rates" is Null then 'Start'
when "WoW Growth Rates" > 0 Then 'Growth' else 'Decay' end as type,
*
from cte
Run a query to Download Data