brb2jmerge6
    Updated 2022-09-29
    WITH miners AS (
    SELECT distinct miner
    FROM ethereum.core.fact_blocks
    where BLOCK_TIMESTAMP <='2022-09-14'
    )

    SELECT
    BLOCK_TIMESTAMP::date as date,
    sum (AMOUNT_IN) as ETH_amounts,
    case
    when ORIGIN_FROM_ADDRESS IN (SELECT * FROM miners) then 'Miners'
    else 'Others'
    end as type

    from ethereum.core.ez_dex_swaps
    where SYMBOL_IN='WETH'
    and BLOCK_TIMESTAMP >='2022-06-01'
    group by 1,3
    Run a query to Download Data