shreyash-5873Untitled Query
Updated 2021-07-27
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
›
⌄
with specific_voting_power as (select
date(block_timestamp) as block_date,
l.vp_address,
l.operator_address,
l.delegator_address,
l.label,
avg(voting_power) as avg_daily_voting_power
from terra.validator_voting_power vp
inner join terra.validator_labels l
on l.vp_address = vp.address
where l.label = 'B-Harvest'
group by 1, 2, 3, 4, 5
order by avg(voting_power) desc),
validator_delegation as (select
*
from terra.daily_balances
where address_label = 'B-Harvest'
and balance_type = 'staked'
and currency = 'LUNA'
)
select
*
from specific_voting_power s
inner join validator_delegation d
on s.block_date = d.date
Run a query to Download Data