datavortexTransaction Growth
    Updated 2024-10-31

    WITH WeeklyTransactions AS (
    -- Arbitrum Blockchain transactions
    SELECT
    DATE_TRUNC('week', block_timestamp) AS TimeLine,
    COUNT(DISTINCT tx_hash) AS TransactionCount,
    'Arbitrum' AS Blockchain
    FROM arbitrum.defi.ez_dex_swaps
    WHERE symbol_in = 'USDC'
    OR symbol_out = 'USDC'
    GROUP BY TimeLine

    UNION ALL

    -- Base Blockchain transactions
    SELECT
    DATE_TRUNC('week', block_timestamp) AS TimeLine,
    COUNT(DISTINCT tx_hash) AS TransactionCount,
    'Base' AS Blockchain
    FROM base.defi.ez_dex_swaps
    WHERE symbol_in = 'USDC'
    OR symbol_out = 'USDC'
    GROUP BY TimeLine

    UNION ALL

    -- Solana Blockchain transactions
    SELECT
    DATE_TRUNC('week', block_timestamp) AS TimeLine,
    COUNT(DISTINCT tx_id) AS TransactionCount,
    'Solana' AS BlockChain
    FROM solana.defi.ez_dex_swaps
    WHERE swap_from_symbol = 'USDC'
    OR swap_from_symbol = 'USDC'
    GROUP BY TimeLine
    )
    QueryRunArchived: QueryRun has been archived