bachistarknet eth deposits
    Updated 2022-06-29

    -- deposits
    /*select date(block_timestamp) as day, count(distinct from_address) as depositors,
    round(sum(eth_value),2) as total_eth_deposited from ethereum.core.fact_transactions
    where to_address = '0xae0ee0a63a2ce6baeeffe56e7714fb4efe48d419'
    group by day
    order by day desc*/

    -- withdrawls
    with withdrawls as (
    select date(block_timestamp) as day, count(distinct event_inputs:receiver) as users, round(sum(event_inputs:amount/1e18),2) as total_eth
    from ethereum.core.fact_event_logs
    where contract_address = '0xae0ee0a63a2ce6baeeffe56e7714fb4efe48d419' and event_name = 'LogWithdrawal'
    group by day order by day desc
    ),
    deposits as (
    select date(block_timestamp) as day, count(distinct from_address) as users,
    round(sum(eth_value),2) as total_eth from ethereum.core.fact_transactions
    where to_address = '0xae0ee0a63a2ce6baeeffe56e7714fb4efe48d419'
    group by day order by day desc
    )

    select *, 'Withdraws' as tran_type from withdrawls
    union select *, 'Deposits' as tran_type from deposits

    /*select date(block_timestamp) as day,
    round(sum(eth_value),2) as total_eth
    from ethereum.core.fact_transactions
    where from_address = '0xae0ee0a63a2ce6baeeffe56e7714fb4efe48d419'
    group by day
    order by day desc*/
    Run a query to Download Data