with A_sol as ( select min(block_timestamp::date) as day , signers
from solana.core.fact_transactions----I US GENERAL TABEL
where block_timestamp::date BETWEEN '2022-06-01'and '2022-06-19'----19 DAY
group by 2), B_sol as ( select min(block_timestamp::date) as day , signers
from solana.core.fact_transactions
where signers in ( select signers from A_sol)
and block_timestamp::date BETWEEN '2022-07-01' and '2022-07-19'
group by 2)
select 'ALL_user' as type , count(DISTINCT(signers)) as NUMBER_OF_user from A_sol
group by 1
UNION
select 'ACTIV_user' as type, count(DISTINCT(signers)) as NUMBER_OF_user from B_sol
group by 1