Query editor
WITH Runiverse_items_trades AS (SELECTDATE_TRUNC('week', block_time) AS trade_week,ROUND(SUM(CAST(amount_usd AS DOUBLE)), 1) AS volume_usd,COUNT(DISTINCT unique_trade_id) AS number_of_sales,ROUND(MAX(amount_usd), 1) AS top_trade_usd,COUNT(DISTINCT buyer) AS distinct_buyer_wallets,ROUND(SUM(royalty_fee_amount_usd), 1) AS monthly_creator_royalties_usd,COUNT(DISTINCT tx_from) + COUNT(DISTINCT tx_to) AS user_countFROM nft.tradesWHERE blockchain = 'ronin'AND nft_contract_address = FROM_HEX('0x578b65568b7a6a081a477748590774a64d8a4923')AND block_time >= DATE '2024-07-01'GROUP BY 1), cumulative_trades AS (SELECTtrade_week,volume_usd,ROUND(SUM(volume_usd) OVER (ORDER BY trade_week ASC), 1) AS cumulative_volume_usd,number_of_sales,ROUND(SUM(number_of_sales) OVER (ORDER BY trade_week ASC), 1) AS cumulative_total_sales,top_trade_usd,distinct_buyer_wallets,monthly_creator_royalties_usd,ROUND(SUM(monthly_creator_royalties_usd) OVER (ORDER BY trade_week ASC), 1) AS cumulative_creator_royalties,user_count,ROUND(SUM(user_count) OVER (ORDER BY trade_week ASC), 1) AS cumulative_user_countFROM Runiverse_items_trades)SELECTtrade_week,volume_usd,cumulative_volume_usd,number_of_sales,cumulative_total_sales,top_trade_usd,distinct_buyer_wallets,monthly_creator_royalties_usd,cumulative_creator_royalties,user_count,cumulative_user_countFROM cumulative_tradesORDER BY trade_week ASC;