binhachonSushi Reward Program for Farmers
Updated 2022-05-04
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
›
⌄
with claim_transactions as (
select
-- block_timestamp,
to_address as account,
sum(amount) as claimed_amount
from ethereum_core.ez_token_transfers
where block_timestamp >= '2021-10-22 09:47:00.000' --tx_hash = '0x4c22712b3a44eeae6266ee9c8c2f75316bd7d712736792e702e04b094e2fa4c1'
and from_address = lower('0x1026cbed7b7E851426b959BC69dcC1bf5876512d')
and symbol = 'SUSHI'
group by 1
-- and event_name = 'Claimed'
),
eligible_addresses as (
select
address,
amount
from ethereum_sushi.dim_distributor_reward_schedule
where lower(address) not in (select account from claim_transactions)
and merkle_root = '0x015e6c2cd1a4d6fa77aa1884c436b2435aae4beab5c9a091f18fd0c00dc7e577'
)
select
count(address) as "Number of eligible addresses that have not claimed anything so far",
sum(amount) as "Total unclaimed rewards by addresses that have not claimed anything so far"
from eligible_addresses
Run a query to Download Data