Query editor
WITH sales(sale, pool, fee_id, launch, ord) AS (VALUES(0x7d30932f10d9d0b3a7b1c9d8fb19c5dc61f6b25b, 0x1270983d52772b76aca2979bdceb4e999a7c223c, 0, '#1 Airway (AIRWA)', 1),(0x2843fb30efdabaf0d8384146a31490e65e8a5847, 0x8a22a8a5ea033c0b57d1ec39c135624cfcb9b8c5, 1, '#2 Late Night Onchain (LNOC)', 2),(0x45e5627396cf4b0dd9ccd94ccdfe4eb10593f0a2, 0x461c3afb3b5f0a8ebed81e43dd6c7b1d5a47b66a, 2, '#3 Robin Strategy (RSTR)', 3)),buys AS (SELECT s.launch, s.ord,SUM(CAST(bytearray_to_uint256(bytearray_substring(l.data, 1, 32)) AS double)) / 1e18 AS raised_eth,COUNT(DISTINCT l.topic1) AS wallets,COUNT(*) AS contributions,date_diff('minute', MIN(l.block_time), MAX(l.block_time)) AS fill_minutesFROM robinhood.logs lJOIN sales s ON l.contract_address = s.saleWHERE l.block_date >= DATE '2026-07-25'AND l.topic0 = 0xa9a40dec7a304e5915d11358b968c1e8d365992abf20f82285d1df1b30c8e24cGROUP BY 1, 2),swp AS (SELECT s.launch,SUM(ABS(CAST(varbinary_to_int256(bytearray_substring(l.data, 33, 32)) AS double))) / 1e18 AS vol_eth,COUNT(*) AS swaps,COUNT(DISTINCT l.tx_from) AS tradersFROM robinhood.logs lJOIN sales s ON l.contract_address = s.poolWHERE l.block_date >= DATE '2026-07-25'AND l.topic0 = 0xc42079f94a6350d7e6235f29174924f928cc2ac818eb64fed8004e115fbcca67GROUP BY 1),fees AS (SELECT s.launch,SUM(CAST(bytearray_to_uint256(bytearray_substring(l.data, 33, 32)) AS double)) / 1e18 AS fees_weth,COUNT(*) AS harvestsFROM robinhood.logs lJOIN sales s ON bytearray_to_uint256(l.topic1) = CAST(s.fee_id AS uint256)WHERE l.block_date >= DATE '2026-07-25'AND l.contract_address = 0xfe387931f2ebe14a386b41262932b153c4c742b4AND l.topic0 = 0x60335fc6da5dde7dc66197a635e02eb0dafc452a299f77200b64358c94cdb616GROUP BY 1)SELECT b.ord, b.launch, b.raised_eth, b.wallets, b.contributions, b.fill_minutes,w.vol_eth, w.swaps, w.traders, COALESCE(f.fees_weth, 0) AS fees_weth,COALESCE(f.harvests, 0) AS fee_harvestsFROM buys bLEFT JOIN swp w ON w.launch = b.launchLEFT JOIN fees f ON f.launch = b.launchUNION ALLSELECT 4, 'TOTAL', SUM(b.raised_eth), SUM(b.wallets), SUM(b.contributions), NULL,SUM(w.vol_eth), SUM(w.swaps), SUM(w.traders), SUM(COALESCE(f.fees_weth, 0)),SUM(COALESCE(f.harvests, 0))FROM buys bLEFT JOIN swp w ON w.launch = b.launchLEFT JOIN fees f ON f.launch = b.launchORDER BY 1