with top_user as ( select min(block_timestamp::date) as date ,from_address
from gnosis.core.fact_transactions
group by 2)
,
new_user as ( select date, from_address
from top_user
where date between '2022-10-04' and '2022-10-08' )
select to_address, count(DISTINCT(tx_hash)) as total_tx
from gnosis.core.fact_transactions
where from_address in (select from_address from new_user)
and block_timestamp::date between '2022-10-04' and '2022-10-08'
group by 1
order by 2 desc
limit 10