Query editor
WITH registrant_users AS (SELECT DISTINCTDATE_TRUNC('month', ic.block_time) AS month,o.owner_account AS user_addressFROM solana.instruction_calls icINNER JOIN dune.whatsup1047.result_current_owners_v_2 oON element_at(ic.account_arguments, 3) = o.name_accountWHERE ic.executing_account = 'namesLPneVptA9Z5rqUDD9tMTWEJwofgaYwp8cawRkX'AND ic.tx_success = TRUEAND BYTEARRAY_TO_BIGINT(BYTEARRAY_SUBSTRING(ic.data, 1, 1)) = 0AND element_at(ic.account_arguments, 6) = '58PwtjSDuFHuUkYjH9BYnnQKHfwo9reZhC2zMJv9JPkx'AND ic.block_time >= DATE_TRUNC('month', DATE_ADD('month', -1, CURRENT_DATE)))SELECTdate_format(COALESCE(r.month, t.trade_month), '%b %Y') AS month,count(DISTINCT r.user_address) AS registrant_users,count(DISTINCT t.trader_account) AS trader_users,count(DISTINCT COALESCE(r.user_address, t.trader_account)) AS total_active_usersFROM registrant_users rFULL OUTER JOIN dune.solananameservice.result_active_users_secondary_sales_60_days tON r.month = t.trade_monthGROUP BY COALESCE(r.month, t.trade_month)ORDER BY COALESCE(r.month, t.trade_month)