0xaimanGENE stake size
Updated 2022-05-28
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
›
⌄
select stake_size, count(user_addr) as n_address
from (
select user_addr,
sum(gene_staked) as t_gene_staked,
case when t_GENE_STAKED>=0 and t_gene_staked<100 then 'Small Fish staker'
when t_GENE_STAKED>=100 and t_gene_staked<1000 then 'Shark staker'
when t_gene_staked>=1000 then 'Whale staker'
--else null
end as stake_size
from (select block_timestamp as t,
instructions[0]:accounts[0] as user_addr,
PRE_TOKEN_BALANCES,
PRE_TOKEN_BALANCES[0]:uiTokenAmount:uiAmountString as gene_staked
from solana.fact_transactions
where --tx_id='5pviDajMbZYBoDfopXKwyd5cJGwJV3SCwXd288BC8xE8REVG8NHmWWPmnazJxumt1QK9xYMWZuBVMuSxnHuR9ecZ' AND
instructions[0]:programId='StaKe9nb7aUjXpjpZ45o6uJBsZxj2BWCDBtjk8LCg2v')
group by 1 order by 1
)
where t_gene_staked is not null
group by 1 order by 1
--where tx_id='65mbYpb65p7aFePkbsJQxCNKt4XNE6jny4dAYjKHzApmzAFEA9EqXo2uxVXJVimkVdakkTU3bzJJ1TJBmmih6tqJ'
Run a query to Download Data