select sum(sum(event_inputs:value/pow(10,9))) over (order by date_trunc('day', block_timestamp)) AS amount,
date_trunc('day', block_timestamp) as date_time
from ethereum.core.fact_event_logs
where date_trunc('day', block_timestamp) >= '2022-04-02'
and origin_function_signature like '%0xd866c9d8%'
and contract_address in ('0xf59257e961883636290411c11ec5ae622d19455e')
and event_inputs:to in ('0x759c6de5bca9ade8a1a2719a31553c4b7de02539')
group by date_trunc('day', block_timestamp)