theericstoneAirdrop Number 3 Hist Full
    Updated 2023-09-29
    -- forked from Airdrop Hist Full @ https://flipsidecrypto.xyz/edit/queries/8985f0e7-df39-4d34-b99c-5be585bec61e

    with alldrops as (
    select to_address, raw_amount / pow(10,18) as amount FROM
    optimism.core.fact_token_transfers
    where block_timestamp > '2023-09-18'
    and from_address = lower('0x2501c477D0A35545a387Aa4A3EEe4292A9a8B3F0')
    and contract_address = lower('0x4200000000000000000000000000000000000042')
    )

    ,bins as (
    select
    floor(amount/50.00)*50 as bin_floor,
    count(to_address) as count
    from alldrops
    group by 1
    order by 1
    -- same query as above, just in a CTE
    )

    select
    bin_floor,
    bin_floor || ' - ' || (bin_floor + 50) as bin_range,
    count
    from bins
    order by 1;


    Run a query to Download Data