aPrioriMAGMA_TVL
    Updated 5 days ago
    with stake_event_logs_dim as
    (
    SELECT
    tx_hash,
    ORIGIN_FUNCTION_SIGNATURE
    from monad.testnet.fact_event_logs
    where TX_SUCCEEDED
    -- and ORIGIN_FUNCTION_SIGNATURE = '0xd5575982'
    -- and ORIGIN_TO_ADDRESS = '0x2c9c959516e9aaedb2c748224a41249202ca8be7'
    and CONTRACT_ADDRESS = '0x2c9c959516e9aaedb2c748224a41249202ca8be7'
    -- and tx_hash='0xc6e725af3da23a9d76daf6d14fb017dc6b527d27e651e20a5f35bcdb818171d3'
    group by 1,2
    ),

    lst_deposit_action_dim as
    (
    select
    BLOCK_TIMESTAMP
    ,FROM_ADDRESS
    ,TO_ADDRESS
    ,tx_hash
    ,value as stake_amount
    from monad.testnet.fact_traces
    where tx_hash in (select tx_hash from stake_event_logs_dim where ORIGIN_FUNCTION_SIGNATURE='0xd5575982')
    and TO_ADDRESS='0x2c9c959516e9aaedb2c748224a41249202ca8be7'
    and value>0
    ),



    lst_redeem_action_dim as
    (
    select
    BLOCK_TIMESTAMP
    ,FROM_ADDRESS
    ,TO_ADDRESS
    Last run: 5 days ago
    STAT_DATE
    TVL_DELTA
    TVL
    1
    2025-02-18 00:00:00.000-46.8435868714.175983738
    2
    2025-02-19 00:00:00.000805.414751112809.59073485
    3
    2025-02-20 00:00:00.00095570.86129562896380.452030478
    4
    2025-02-21 00:00:00.000107862.941374323204243.393404801
    5
    2025-02-22 00:00:00.0001387.770712196205631.164116997
    6
    2025-02-23 00:00:00.000-31232.986866476174398.17725052
    7
    2025-02-24 00:00:00.00013792.954194669188191.13144519
    8
    2025-02-25 00:00:00.0003067.348278179191258.479723369
    9
    2025-02-26 00:00:00.00018307.286296478209565.766019846
    10
    2025-02-27 00:00:00.00016776.83604493226342.602064777
    11
    2025-02-28 00:00:00.00015778.357687314242120.959752091
    12
    2025-03-01 00:00:00.00012600.234521053254721.194273144
    13
    2025-03-02 00:00:00.000-17015.609903557237705.584369587
    14
    2025-03-03 00:00:00.000-789.336869379236916.247500208
    15
    2025-03-04 00:00:00.000-927.625094338235988.62240587
    16
    2025-03-05 00:00:00.00033061.437105167269050.059511037
    17
    2025-03-06 00:00:00.00019370.797916795288420.857427832
    18
    2025-03-07 00:00:00.000-1201.902779671287218.954648161
    19
    2025-03-08 00:00:00.0002936.630903162290155.585551323
    20
    2025-03-09 00:00:00.0003475.832998054293631.418549377
    24
    1KB
    32s