Zanyar_98Total number of daily participants in auctions - All
    Updated 2022-09-20
    WITH Project_On_Ethereum AS (
    SELECT Contract_Address
    FROM ethereum.core.fact_event_logs
    WHERE ORIGIN_TO_ADDRESS='0x7603a35af5cf10b113f167d424eb75bb7062c8ce' AND
    ORIGIN_FUNCTION_SIGNATURE = '0xfa18022c' AND EVENT_NAME='AuctionTimeUpdated' AND BLOCK_TIMESTAMP < CURRENT_DATE),

    ETH_P AS (SELECT Block_Timestamp::date AS DAYS, COUNT(DISTINCT(FROM_ADDRESS)) AS "Number of participants", 'Ethereum' AS NETWORK
    FROM ethereum.core.fact_transactions
    WHERE To_ADDRESS IN (SELECT Contract_Address FROM Project_On_Ethereum) AND BLOCK_TIMESTAMP < CURRENT_DATE
    GROUP BY DAYS),
    Project_On_Polygon AS (
    SELECT Contract_Address
    FROM polygon.core.fact_event_logs
    WHERE ORIGIN_TO_ADDRESS='0xc040f84cf7046409f92d578ef9040fe45e6ef4be' AND
    ORIGIN_FUNCTION_SIGNATURE = '0xfa18022c' AND EVENT_NAME='AuctionTimeUpdated' AND BLOCK_TIMESTAMP < CURRENT_DATE),
    Polygon_P AS (
    SELECT Block_Timestamp::date AS DAYS,COUNT(DISTINCT(FROM_ADDRESS)) AS "Number of participants", 'Polygon' AS NETWORK
    FROM polygon.core.fact_transactions
    WHERE To_ADDRESS IN (SELECT Contract_Address FROM Project_On_Polygon) AND BLOCK_TIMESTAMP < CURRENT_DATE
    GROUP BY DAYS),

    Project_On_Avalanche AS (
    SELECT Contract_Address
    FROM avalanche.core.fact_event_logs
    WHERE ORIGIN_TO_ADDRESS='0x438a2b1c6c715fb1b051c04ca65755560d8b8d43' AND
    ORIGIN_FUNCTION_SIGNATURE = '0xfa18022c' AND EVENT_NAME='AuctionTimeUpdated' AND BLOCK_TIMESTAMP < CURRENT_DATE),

    Avalanche_P AS (SELECT Block_Timestamp::date AS DAYS,COUNT(DISTINCT(FROM_ADDRESS)) AS "Number of participants", 'Avalanche' AS NETWORK
    FROM avalanche.core.fact_transactions
    WHERE To_ADDRESS IN (SELECT Contract_Address FROM Project_On_Avalanche) AND BLOCK_TIMESTAMP < CURRENT_DATE
    GROUP BY DAYS),

    Project_On_BSC AS (
    SELECT Contract_Address
    Run a query to Download Data