Eman-RazDaily Net flows to Lido
    Updated 2023-06-24
    with tab1 as (SELECT block_timestamp::date as "Day", sum(amount) as "ETH Staked"
    FROM ethereum.core.ez_token_transfers
    WHERE contract_address = lower('0xae7ab96520DE3A18E5e111B5EaAb095312D7fE84')
    AND from_address = '0x0000000000000000000000000000000000000000'
    and block_timestamp::date>='2023-05-15'
    group by 1
    order by 1),

    tab2 as (SELECT BLOCK_TIMESTAMP::DATE AS "Day", sum(amount) as "ETH Withdrawn"
    from ethereum.core.ez_eth_transfers
    where ETH_FROM_ADDRESS='0x889edc2edab5f40e902b864ad4d7ade8e412f9b1'
    group by 1
    order by 1)

    SELECT TAB1."Day" as "Day", "ETH Staked"-"ETH Withdrawn" as "Net Volume"
    from tab1 left join tab2 on tab1."Day"=tab2."Day"
    where "ETH Withdrawn" is not null
    order by 1
    Run a query to Download Data