select
date_trunc('day', block_timestamp) as Days,
sum(msg_value:coins[0]:amount) / pow(10,6) as Deposits
from terra.msgs
where msg_value:execute_msg:deposit_stable is not null
and tx_status = 'SUCCEEDED'
and days < CURRENT_DATE
group by 1
order by 1 desc
limit 14