0xHaM-dTx & Users Ttl Borrow
    Updated 2025-02-16
    -- forked from Tx & Users Ttl Borrow @ https://flipsidecrypto.xyz/studio/queries/55795084-0826-449f-990f-c5e2b5a98c2f

    WITH ariesEventTb AS (
    SELECT
    BLOCK_TIMESTAMP,
    TX_HASH,
    SENDER as user
    FROM aptos.core.fact_events
    JOIN aptos.core.fact_transactions using(tx_hash)
    WHERE
    EVENT_TYPE ILIKE '0x9770fa9c725cbd97eb50b2be5f7416efdfd1f1554beb0750d4dae4c64e860da3::reserve::SyncReserveDetailEvent%'
    AND EVENT_MODULE = 'reserve'
    )
    ----------------------------
    -----------Aptin------------
    ----------------------------
    ,
    aptinEventTb AS (
    SELECT
    BLOCK_TIMESTAMP,
    TX_HASH,
    SENDER as user
    FROM aptos.core.fact_events
    JOIN aptos.core.fact_transactions using(tx_hash)
    WHERE EVENT_TYPE = '0x3c1d4a86594d681ff7e5d5a233965daeabdc6a15fe5672ceeda5260038857183::pool::OperEvent'
    AND SUCCESS = TRUE
    )
    ----------------------------
    ----------Echelon-----------
    ----------------------------
    ,
    echelonEventTb as (
    SELECT
    BLOCK_TIMESTAMP,
    TX_HASH,
    SENDER AS user,
    Last run: about 2 months ago
    N_TXS
    N_USERS
    1
    3030431683262
    1
    18B
    323s