Specterdistribution by takers/makers:Transac
    Updated 2024-11-04
    WITH predictfun AS (
    SELECT
    COUNT(DISTINCT tx_hash) as tx_count,
    decoded_log:taker AS taker,
    decoded_log:maker AS maker
    FROM blast.core.fact_decoded_event_logs
    WHERE contract_address IN ('0x739f0331594029064c252559436edce0e468e37a', '0x6a3796c21e733a3016bc0ba41edf763016247e72')
    AND event_name = 'OrderFilled'
    GROUP BY maker, taker
    )

    SELECT
    COUNT(DISTINCT taker) AS takers,
    COUNT(DISTINCT maker) AS Makers,
    CASE
    WHEN tx_count < 10 THEN '<10'
    WHEN tx_count >= 10 AND tx_count < 20 THEN '10-20'
    WHEN tx_count >= 20 AND tx_count < 30 THEN '20-30'
    WHEN tx_count >= 30 AND tx_count < 40 THEN '30-40'
    WHEN tx_count >= 40 THEN '>40'
    END AS num_transactions
    FROM predictfun
    GROUP BY num_transactions
    ORDER BY num_transactions;


    QueryRunArchived: QueryRun has been archived