Query editor
-- Frankencoin has NO on-chain collateral registry. Approval is emergent:-- an ORIGINAL position that survived the veto window whitelists its collateral;-- clones inherit. This derives the de facto whitelist.WITH originals AS (SELECT evt_block_time AS opened_at, position, original, collateral, ownerFROM frankencoin_ethereum.mintinghub_evt_positionopenedWHERE position = original -- originals only),denied AS (SELECT DISTINCT contract_address AS positionFROM frankencoin_ethereum.position_evt_positiondenied),activity AS (SELECT contract_address AS position,max_by(minted, evt_block_number) / 1e18 AS current_mintedFROM frankencoin_ethereum.position_evt_mintingupdateGROUP BY 1)SELECT tk.symbol,o.collateral,COUNT(*) AS approved_originals,COUNT(*) FILTER (WHERE COALESCE(a.current_minted, 0) > 0) AS active_originals,SUM(COALESCE(a.current_minted, 0)) AS minted_via_originals_zchf,MIN(o.opened_at) AS first_approvedFROM originals oLEFT JOIN denied d ON d.position = o.positionLEFT JOIN activity a ON a.position = o.positionLEFT JOIN tokens.erc20 tk ON tk.contract_address = o.collateral AND tk.blockchain = 'ethereum'WHERE d.position IS NULLAND o.opened_at < NOW() - INTERVAL '5' day -- past veto windowGROUP BY 1, 2ORDER BY minted_via_originals_zchf DESC;