Query editor
WITH pump_fun_daily_active_users AS (-- Pump fun daily active usersSELECTDATE_TRUNC('day', block_time) AS time,COUNT(DISTINCT ELEMENT_AT(account_keys, 1)) AS active_user_amountFROMsolana.transactionsWHERECONTAINS(account_keys, '6EF8rrecthR5Dkzon8Nwu78hRvfCKubJ14M5uBEwF6P')AND success = TRUEAND block_time > NOW() - INTERVAL '3' monthGROUP BYDATE_TRUNC('day', block_time)),pump_fun_daily_new_users AS (-- Pump fun daily new usersSELECTELEMENT_AT(account_keys, 1) AS user,MIN(DATE_TRUNC('day', block_time)) AS first_seen_dateFROMsolana.transactionsWHERECONTAINS(account_keys, '6EF8rrecthR5Dkzon8Nwu78hRvfCKubJ14M5uBEwF6P')AND success = TRUEAND block_time > NOW() - INTERVAL '3' monthGROUP BYELEMENT_AT(account_keys, 1)),daily_new_users_summary AS (SELECTfirst_seen_date AS time,COUNT(DISTINCT user) AS new_users_amount,SUM(COUNT(DISTINCT user)) OVER (ORDER BY first_seen_date) AS cumulative_addressesFROMpump_fun_daily_new_usersGROUP BYfirst_seen_dateORDER BYfirst_seen_date DESC)-- Final result combining active and new usersSELECTa.time,a.active_user_amount,b.new_users_amount,b.cumulative_addressesFROMpump_fun_daily_active_users AS aLEFT JOINdaily_new_users_summary AS bON a.time = b.timeORDER BYa.time DESC;