0xHaM-dwETH Deposit Rate
    Updated 2022-06-14
    with osmo as (
    select
    block_timestamp::date as date_,
    count(tx_id) as tx_count_osmo,
    sum(tx_count_osmo) over (ORDER BY date_) AS cumm_growth_tx_count_weth_osmo,
    sum(amount/1e18) as deposit_weth_osmo,
    sum(deposit_weth_osmo) over (ORDER BY date_) AS cumm_growth_deposite_weth_osmo
    from osmosis.core.fact_liquidity_provider_actions
    where currency in ('ibc/65381C5F3FD21442283D56925E62EA524DED8B6927F0FF94E21E0020954C40B5',
    'ibc/EA1D43981D5C9A1C4AAEA9C23BB1D4FA126BA9BC7020A25E0AE4AA841EA25DC5')
    and action in ('pool_joined')
    and amount/1e18 > 0
    and date_ > '2022-01-01'
    group by 1
    order by 1
    )
    , sushi as (
    select
    block_timestamp::date as date,
    count(DISTINCT tx_hash) as tx_count_sushi,
    sum(raw_amount/1e18) as deposit_amount_sushi,
    sum(tx_count_sushi) over (ORDER BY date) as cum_tx_count_sushi,
    sum(deposit_amount_sushi) over (ORDER BY date) as cum_deposit_amount_sushi
    from ethereum.core.fact_token_transfers
    where to_address in (select pool_address from ethereum.core.dim_dex_liquidity_pools
    where platform in ('sushiswap')
    and (token0 = '0xc02aaa39b223fe8d0a0e5c4f27ead9083c756cc2'
    or token1 = '0xc02aaa39b223fe8d0a0e5c4f27ead9083c756cc2'))
    and contract_address = '0xc02aaa39b223fe8d0a0e5c4f27ead9083c756cc2'
    and origin_function_signature = '0xe8e33700'
    and date > '2022-01-01'
    group by 1
    order by 1
    )
    , thor as (
    select
    Run a query to Download Data