Query editor
WITH tokentoquestion AS (SELECT token0 AS token, b.conditionid, a.questionIdFROM predict_bnb.umacompatiblectfadapter_evt_questioninitialized aINNER JOIN predict_bnb.conditionaltokens_evt_conditionpreparation bON a.questionId = b.questionIdINNER JOIN predict_bnb.ctfexchange_evt_tokenregistered cON b.conditionId = c.conditionIdUNION ALLSELECT token0 AS token, b.conditionid, a.questionIdFROM predict_bnb.umacompatiblectfadapter_evt_questioninitialized aINNER JOIN predict_bnb.yieldbearingconditionaltokens_evt_conditionpreparation bON a.questionId = b.questionIdINNER JOIN predict_bnb.ctfexchange_evt_tokenregistered cON b.conditionId = c.conditionIdUNION ALLSELECT token0 AS token, b.conditionid, a.questionIdFROM predict_bnb.negriskadapter_evt_questionprepared aINNER JOIN predict_bnb.conditionaltokens_evt_conditionpreparation bON a.questionId = b.questionIdINNER JOIN predict_bnb.negriskctfexchange_evt_tokenregistered cON b.conditionId = c.conditionIdUNION ALLSELECT token0 AS token, b.conditionid, a.questionIdFROM predict_bnb.negriskadapter_evt_questionprepared aINNER JOIN predict_bnb.yieldbearingconditionaltokens_evt_conditionpreparation bON a.questionId = b.questionIdINNER JOIN predict_bnb.negriskctfexchange_evt_tokenregistered cON b.conditionId = c.conditionIdUNION ALLSELECT token0 AS token, b.conditionid, a.questionIdFROM predict_bnb.yieldbearingnegriskadapter_evt_questionprepared aINNER JOIN predict_bnb.conditionaltokens_evt_conditionpreparation bON a.questionId = b.questionIdINNER JOIN predict_bnb.negriskctfexchange_evt_tokenregistered cON b.conditionId = c.conditionIdUNION ALLSELECT token0 AS token, b.conditionid, a.questionIdFROM predict_bnb.yieldbearingnegriskadapter_evt_questionprepared aINNER JOIN predict_bnb.yieldbearingconditionaltokens_evt_conditionpreparation bON a.questionId = b.questionIdINNER JOIN predict_bnb.negriskctfexchange_evt_tokenregistered cON b.conditionId = c.conditionIdUNION ALLSELECT token0 AS token, b.conditionid, a.questionIdFROM predict_bnb.chainlinkupdownadapter_evt_chainlinkupdownadapter__roundcreated aINNER JOIN predict_bnb.conditionaltokens_evt_conditionpreparation bON a.questionId = b.questionIdINNER JOIN predict_bnb.ctfexchange_evt_tokenregistered c