SniperBorrow
    Updated 6 days ago
    with tbl as( select
    'Borrow' as type,
    case
    when c.contract_address = '0x10d0d11a8b693f4e3e33d09bbab7d4afc3c03ef3' then 'WEETH'
    when c.contract_address = '0x49c077b74292aa8f589d39034bf9c1ed1825a608' then 'WETH'
    when c.contract_address = '0x29c85c752e854b0cf2372e6b6c56f260755f5120' then 'PZETH'
    when c.contract_address = '0x4a5c95a0e3fca4148f91ceb637fba0e1080be40e' then 'EZETH'
    when c.contract_address = '0x3c12aa52b014acf7957308808362909b5757cca8' then 'WSTETH'
    when c.contract_address = '0x1773002742a2bcc7666e38454f761ce8fe613de5' then 'RSWETH'
    when c.contract_address = '0xf34253ec3dd0cb39c29cf5eeb62161fb350a9d14' then 'SWETH'
    when c.contract_address = '0x46e3c018798d6de4517a3c98358e4bd8d334b79c' then 'RSETH'
    when c.contract_address = '0xf18de8d3bcf95da46bb667c8a222956199b94e6c' then 'WETH'
    when c.contract_address = '0x522d58aefb7b4f54fc1bd31b5063e55c7984badd' then 'SWELL'
    end as symbol,
    count(DISTINCT a.tx_hash) as tx,
    count(DISTINCT a.from_address) as users,
    sum(DECODED_LOG:assets/pow(10,18)) as volume
    from
    swell.core.fact_transactions a
    left join
    swell.core.fact_event_logs b
    on a.tx_hash = b.tx_hash
    join
    swell.core.ez_decoded_event_logs c
    on b.contract_address = c.contract_address and a.tx_hash = c.tx_hash
    where
    -- a.TO_ADDRESS = '0x08739cbede6e28e387685ba20e6409bd16969cde'
    --and
    c.EVENT_NAME = 'Borrow'
    and b.topics[0] = '0x80b61abbfc5f73cfe5cf93cec97a69ed20643dc6c6f1833b05a1560aa164e24c'
    and c.topics[0] = '0xcbc04eca7e9da35cb1393a6135a199ca52e450d5e9251cbd99f7847d33a36750'
    -- and c.contract_address = '0x10d0d11a8b693f4e3e33d09bbab7d4afc3c03ef3'
    -- and c.contract_address = '0x49c077b74292aa8f589d39034bf9c1ed1825a608'
    and c.TX_SUCCEEDED = 'TRUE'
    GROUP by 1,2

    Last run: 6 days ago
    SYMBOL
    TYPE
    VOLUME_USD
    TX
    USERS
    1
    EZETHBorrow704651.6035661025612
    2
    EZETHRepay559485.4698902194110
    3
    EZETHDeposit3045704.4232346114258
    4
    EZETHWithdraw2367512.392473187934
    5
    PZETHBorrow378593.027534965115
    6
    PZETHRepay379068.98846565125
    7
    PZETHDeposit2000691.523521644726
    8
    PZETHWithdraw1979196.662572353520
    9
    RSETHBorrow281403.915061919209
    10
    RSETHRepay251977.268426099297
    11
    RSETHDeposit600346.0667469097231
    12
    RSETHWithdraw484892.5014823027224
    13
    RSWETHBorrow99733.0445871333513
    14
    RSWETHRepay83585.2563378522711
    15
    RSWETHDeposit587979.1109547079354
    16
    RSWETHWithdraw198877.3504448144930
    17
    WSTETHBorrow254923.9292753886315
    18
    WSTETHRepay186306.0786824478214
    19
    WSTETHDeposit820338.86270535219432
    20
    WSTETHWithdraw427558.62261313110325
    32
    1KB
    14s