Query editor
-- Aave DAO funds moved.---- SCOPE: strict parity with kpk-tx-count base query 8661705 (entity 'Aave').-- wallets: 12 (chain, wallet) rows across arbitrum, avalanche_c, base,-- ethereum, optimism -- exactly the tx-count 'book' rows for Aave.-- window: 2023-12-01 -> 2025-07-01 inclusive, i.e. exclusive bound 2025-08-01-- Closed mandate: the end bound is fixed, not dynamic.---- METHODOLOGY NOTE: this query keeps the transfer-rollup approach (no protocol-- whitelist), matching the Safe <> Gnosis JT query. Every non-internal token-- movement counts; a tx with both an inflow and an outflow is valued at the-- larger leg so swap/bridge pairs are not double counted.---- The literal address list is a partition-pruning hint only; the exact-- (chain, wallet) pairing is enforced by INNER JOIN wallets.WITH wallets AS (SELECT *FROM (VALUES('arbitrum', 0xa1c93d2687f7014aaf588c764e3ce80af016229b, 'a1c9_arbitrum'),('arbitrum', 0xa9e777d56c0ad861f6a03967e080e767ad8d39b6, 'a9e7_arbitrum'),('arbitrum', 0xcaf8155d99a0d11567f039422bb8a0ba003788e5, 'caf8_arbitrum'),('avalanche_c', 0xa1c93d2687f7014aaf588c764e3ce80af016229b, 'a1c9_avalanche'),('base', 0xa1c93d2687f7014aaf588c764e3ce80af016229b, 'a1c9_base'),('ethereum', 0x205e795336610f5131be52f09218af19f0f3ec60, '205e_ethereum'),('ethereum', 0x2ce01c87fec1b71a9041c52caed46fc5f4807285, '2ce0_ethereum'),('ethereum', 0xa1c93d2687f7014aaf588c764e3ce80af016229b, 'a1c9_ethereum'),('ethereum', 0xa9e777d56c0ad861f6a03967e080e767ad8d39b6, 'a9e7_ethereum'),('ethereum', 0xcdb4fa6ba08bf1fb7aa9fdf6002e78edc431a642, 'cdb4_ethereum'),('optimism', 0x205e795336610f5131be52f09218af19f0f3ec60, '205e_optimism'),('optimism', 0xa1c93d2687f7014aaf588c764e3ce80af016229b, 'a1c9_optimism')) AS w(blockchain, wallet, wallet_name)),params AS (SELECTDATE '2023-12-01' AS start_month,DATE '2025-08-01' AS end_month,TIMESTAMP '2023-12-01 00:00:00 UTC' AS start_time,TIMESTAMP '2025-08-01 00:00:00 UTC' AS end_time),raw_transfers AS (SELECTt.blockchain,t.block_time,t.tx_hash,t.contract_address,t.symbol,t.amount,t.amount_usd,t."from",t."to"FROM tokens.transfers tCROSS JOIN params pWHERE t.blockchain IN ('ethereum', 'arbitrum', 'avalanche_c', 'base', 'optimism')AND t.block_month >= p.start_monthAND t.block_month < p.end_monthAND t.block_time >= p.start_time