Ali3NDistribution of $ARENA Airdrop Recipients By Holding Time ($ARENA Airdrop 1st March 2025)
    Updated 2025-03-03
    -- forked from Distribution of $ARENA Airdrop Recipients By Holding Time ($ARENA Airdrop 30 DEC 2024) @ https://flipsidecrypto.xyz/studio/queries/1aa72bad-f6e8-4e86-a22f-86880b38ab01

    -- forked from Distribution of $ARENA Airdrop Recipients By Holding Time @ https://flipsidecrypto.xyz/studio/queries/d52a33fc-b2cc-4d5f-a7f0-1a6d44377309

    with claimerst as (
    select block_timestamp as claim_date,
    to_address as claimer,
    amount as Claimed_Amount
    from avalanche.core.ez_token_transfers
    where contract_address = '0xb8d7710f7d8349a506b75dd184f05777c82dad0c'
    and from_address = '0x30f587903ef022774f5e35151e0e73c196bd755d'
    and block_timestamp >= '2025-03-01 18:30:00.000'
    and origin_function_signature = '0x3b439351'),

    staket as (
    select origin_from_address,
    sum (decoded_log:value/1e18) as Staked_Amount
    from avalanche.core.ez_decoded_event_logs t1 join claimerst t2 on t1.origin_from_address = t2.claimer and t1.decoded_log:value/1e18 <= t2.claimed_amount and t1.block_timestamp > t2.claim_date
    where origin_to_address = '0xeffb809d99142ce3b51c1796c096f5b01b4aaec4'
    and event_name = 'Transfer'
    and origin_function_signature = '0xb6b55f25'
    and contract_address = '0xb8d7710f7d8349a506b75dd184f05777c82dad0c'
    and origin_from_address = decoded_log:from
    group by 1),

    unstaket as (
    select origin_from_address,
    sum (decoded_log:value/1e18) as UnStaked_Amount
    from avalanche.core.ez_decoded_event_logs t1 join claimerst t2 on t1.origin_from_address = t2.claimer and t1.decoded_log:value/1e18 <= t2.claimed_amount and t1.block_timestamp > t2.claim_date
    where origin_to_address = '0xeffb809d99142ce3b51c1796c096f5b01b4aaec4'
    and event_name = 'Transfer'
    and origin_function_signature = '0x2e1a7d4d'
    and contract_address = '0xb8d7710f7d8349a506b75dd184f05777c82dad0c'
    and origin_from_address = decoded_log:to
    group by 1),

    QueryRunArchived: QueryRun has been archived