Query editor
WITH combined_data AS (SELECTCAST(rebate_amount_usd AS DOUBLE) AS rebate_amount_usd,created_atFROM dune.odostreasury.dataset_gas_rebates_part_1UNION ALLSELECTCAST(rebate_amount_usd AS DOUBLE) AS rebate_amount_usd,created_atFROM dune.odostreasury.dataset_gas_rebates_part_2UNION ALLSELECTCAST(rebate_amount_usd AS DOUBLE) AS rebate_amount_usd,created_atFROM dune.odostreasury.dataset_gas_rebates_part_3)SELECTcreated_at,rebate_amount_usd,SUM(rebate_amount_usd) OVER (ORDER BY created_at) AS cumulative_rebate_usdFROM combined_dataORDER BY created_at