Monitize AI$Block Sellers after Claiming Date
    Updated 2024-07-15
    with claimert as(
    SELECT
    distinct TO_ADDRESS as claimer,
    min(Block_timestamp::date) as claim_date,
    sum(amount) as Claimed_Amount
    from(
    select
    distinct TO_ADDRESS,
    --'Cummunity Reward' as type,
    Block_timestamp,
    amount
    from ethereum.core.ez_token_transfers
    where CONTRACT_ADDRESS = lower('0x8fc17671D853341D9e8B001F5Fc3C892d09CB53A')
    and FROM_ADDRESS in ('0x97d7915ee95ed700d4499f702c8e3c7fd12e431b','0x3d577e5aad32b8e9b5b8824fc824d86d09383b4c')
    and ORIGIN_FUNCTION_SIGNATURE = '0x5eddd157'

    UNION

    select
    distinct TO_ADDRESS as claimers,
    --'Cummunity Pre-sale' as type,
    Block_timestamp as claim_dates,
    amount as Claimed_Amounts
    from ethereum.core.ez_token_transfers
    where CONTRACT_ADDRESS = lower('0x8fc17671D853341D9e8B001F5Fc3C892d09CB53A')
    and FROM_ADDRESS = lower('0xb1371882a69f7d9b2cd3c2a02b47f51b107ee5d7')
    )
    group by 1
    ),

    total_claimt as (
    select
    sum(amount) as total_claimed
    from(
    select
    distinct TO_ADDRESS,
    QueryRunArchived: QueryRun has been archived