MasiHourly Transfers of by Addresses
    Updated 2024-10-12
    with tb1 as (select from_address,
    sum(amount) as token_amount
    from near.core.ez_token_transfers
    where symbol in ('USDC','USDT','USDT.e','WUSDC')
    and block_timestamp::date >= '2024-08-06'
    group by 1
    having token_amount > 500000)
    ,
    tb2 as (select to_address,
    sum(amount) as token_amount
    from near.core.ez_token_transfers
    where symbol in ('USDC','USDT','USDT.e','WUSDC')
    and block_timestamp::date >= '2024-08-06'
    group by 1
    having token_amount > 500000)

    select trunc(block_timestamp,'hour') as hourly,
    sum(amount) as token_amount
    from near.core.ez_token_transfers
    where symbol in ('USDC','USDT','USDT.e','WUSDC')
    and block_timestamp::date >= '2024-08-06'
    and (from_address in (select from_address from tb1)
    or from_address in (select to_address from tb2)
    or to_address in (select from_address from tb1)
    or to_address in (select to_address from tb2))
    group by 1
    QueryRunArchived: QueryRun has been archived