datavortexethena top depositor
    Updated 2025-01-09
    WITH ethena_funds AS (
    SELECT
    t."from" AS address,
    t.amount_usd,
    t.tx_hash
    FROM $query('9c34be15-06fc-4ab1-a405-abcb5a2146cc') t
    WHERE t."from" IS NOT NULL
    AND t.amount_usd IS NOT NULL
    AND t.tx_hash IS NOT NULL
    ),
    aggregated_data AS (
    SELECT
    address,
    SUM(amount_usd) AS total_amount_usd,
    COUNT(DISTINCT tx_hash) AS total_transactions
    FROM ethena_funds
    GROUP BY address
    )
    SELECT
    'Ethena' AS project,
    address AS top_depositor,
    total_amount_usd,
    total_transactions
    FROM aggregated_data
    ORDER BY total_amount_usd DESC
    LIMIT 10;

    QueryRunArchived: QueryRun has been archived