datavortexrestake fee in usd
    Updated 2025-04-25
    WITH base AS (
    SELECT DISTINCT tx_hash, block_timestamp
    FROM ethereum.core.ez_decoded_event_logs
    WHERE contract_address = LOWER('0xfae103dc9cf190ed75350761e95403b7b8afa6c0')
    AND event_name = 'Transfer'
    AND decoded_log:from = '0x0000000000000000000000000000000000000000'
    ),
    tx_fees AS (
    SELECT tx_hash, tx_fee, block_timestamp
    FROM ethereum.core.fact_transactions
    ),
    eth_price AS (
    SELECT hour AS price_hour, price
    FROM ethereum.price.ez_prices_hourly
    WHERE symbol = 'WETH'
    )
    SELECT
    DATE_TRUNC('week', b.block_timestamp) AS week,
    SUM(f.tx_fee * p.price) AS weekly_fee_usd,
    SUM(SUM(f.tx_fee * p.price)) OVER (ORDER BY DATE_TRUNC('week', b.block_timestamp)) AS cumulative_fee_usd
    FROM base b
    JOIN tx_fees f ON b.tx_hash = f.tx_hash
    JOIN eth_price p ON DATE_TRUNC('hour', f.block_timestamp) = p.price_hour
    GROUP BY DATE_TRUNC('week', b.block_timestamp)
    ORDER BY week;

    Last run: about 1 month ago
    WEEK
    WEEKLY_FEE_USD
    CUMULATIVE_FEE_USD
    1
    2024-01-29 00:00:00.00019405.45727948219405.457279482
    2
    2024-02-05 00:00:00.00021687.87565197941093.332931461
    3
    2024-02-12 00:00:00.0009268.3299991150361.662930572
    4
    2024-02-19 00:00:00.00026621.17515302176982.838083592
    5
    2024-02-26 00:00:00.00022595.12026763399577.958351226
    6
    2024-03-04 00:00:00.00018028.918984371117606.877335597
    7
    2024-03-11 00:00:00.00030071.653348432147678.530684029
    8
    2024-03-18 00:00:00.00067569.75610404215248.286788069
    9
    2024-03-25 00:00:00.00053442.303413043268690.590201112
    10
    2024-04-01 00:00:00.00025309.872363487294000.462564599
    11
    2024-04-08 00:00:00.00046245.870146483340246.332711083
    12
    2024-04-15 00:00:00.00014759.648215832355005.980926914
    13
    2024-04-22 00:00:00.0007943.567631687362949.548558601
    14
    2024-04-29 00:00:00.0004988.807623953367938.356182554
    15
    2024-05-06 00:00:00.0007019.230928433374957.587110987
    16
    2024-05-13 00:00:00.0003736.853688949378694.440799937
    17
    2024-05-20 00:00:00.0002971.88969137381666.330491307
    18
    2024-05-27 00:00:00.0003889.684322475385556.014813782
    19
    2024-06-03 00:00:00.0002469.225429491388025.240243273
    20
    2024-06-10 00:00:00.0003002.47699339391027.717236662
    65
    4KB
    108s