MLDZMNstETH to ETH
    Updated 2022-06-16
    with tb1 as (select
    date_trunc('week',HOUR) as weeks,
    avg(PRICE) as STETH_USD
    from ethereum.core.fact_hourly_token_prices
    where SYMBOL='stETH'
    and HOUR>=CURRENT_DATE-365
    group by 1
    ),

    tb2 as (select
    date_trunc('week',hour) as weeks,
    avg(price) as ETH_USD
    from ethereum.core.fact_hourly_token_prices
    where weeks>=CURRENT_DATE-365
    and SYMBOL='WETH'
    group by 1),

    tb3 as (select
    distinct ORIGIN_FROM_ADDRESS as wallets,
    sum(AMOUNT) as stake_vol,
    count(distinct tx_hash) as number_stakes
    from ethereum.core.ez_token_transfers

    where ORIGIN_TO_ADDRESS=lower('0xae7ab96520DE3A18E5e111B5EaAb095312D7fE84')
    and from_address='0x0000000000000000000000000000000000000000'
    and BLOCK_TIMESTAMP>=CURRENT_DATE-365
    group by 1)

    select
    Date_trunc('week',BLOCK_TIMESTAMP) as weeks,
    sum(AMOUNT_IN) as stETH_input,
    stETH_input*ETH_USD as amount_input,
    sum(AMOUNT_OUT) as ETH_output,
    Run a query to Download Data