freemartianPika Airdrop - Airdrop Stakers
    Updated 2023-06-29
    with claims as (
    select
    tx_hash,
    to_address,
    amount
    from optimism.core.ez_token_transfers
    where from_address = '0x67a9e34a763395266612ffc8c9305eb2fca4d4be'
    and contract_address = '0x1508fbb7928aedc86bee68c91bc4afcf493b0e78'
    and origin_function_signature = '0x3d13f874'),

    stake as (
    select
    tx_hash,
    from_address,
    amount
    from optimism.core.ez_token_transfers
    where to_address = '0x21a4a5c00ab2fd749ebec8282456d93351459f2a'
    and contract_address = '0x1508fbb7928aedc86bee68c91bc4afcf493b0e78'
    and origin_function_signature = '0xb6b55f25')

    select
    count(distinct from_address) as Stakers_Count, sum(s.amount) as esPIKA_staked_from_airdrop
    from stake s inner join claims c on s.from_address = c.to_address
    where s.amount <= c.amount
    --and from_address = '0x39fe1beef05ded01d35c2b97e3fb6939d4f0aee3'
    --group by 1
    Run a query to Download Data