select date_trunc('day',block_timestamp) as block_day,
count (distinct(SIGNERS)) as users,
sum(INNER_INSTRUCTIONS[3]:instructions[2]:parsed:info:amount/1000000000) as amount_staked
from flipside_prod_db.solana.fact_transactions
where instructions[0]:programId ='StaKe9nb7aUjXpjpZ45o6uJBsZxj2BWCDBtjk8LCg2v'
and block_timestamp >= '2022-05-17'
group by block_day
order by block_day