Query editor
with stakes as (select block_time AS timestamp,(bytearray_to_uint256 (topic2) / 1e18) as amountfrom ethereum.logswhere contract_address=0x6345A9F7e7069D478FFF3595f1522f28d8405151 and topic0=0x5c2a6a1463525d8014567a55ba40a336867d93044c6e19dbb3577b16fcba479dorder by block_time)SELECTtimestamp, amount, SUM(amount) over (ORDER BY timestamp) AS cumulative_stakesFROM stakesORDER BY 1 DESC