with list as (
select proposer as wallet_address, block_timestamp, tx_id from (
select proposer, block_timestamp, tx_id, ROW_NUMBER() OVER (PARTITION BY proposer ORDER BY block_timestamp ASC) AS n from flow.core.fact_transactions
where tx_succeeded = 1
and block_timestamp::date >= '2022-01-01' qualify n = 1
)
)
select wallet_address from list
where exists (select * from flow.core.fact_transactions a where list.wallet_address = a.proposer
and tx_succeeded = 1
and a.block_timestamp::date > list.block_timestamp
and a.block_timestamp <= list.block_timestamp + INTERVAL '1 month'
and a.tx_id != list.tx_id
)