Query editor
-- $NAT is a NATIVE BITCOIN token (TAP Protocol DMT), minted from Bitcoin block headers since block 817,709.-- This ERC-20 (0x249130f5e2dd4cf278180c0df8273f3592ad1247) is its BRIDGED Ethereum representation.-- Ethereum-side figures only. Bitcoin emission and pool attribution: https://dune.com/bitcoinsecuritybudget/bitcoin-second-subsidy-- PANEL 5: Wormhole Portal bridge 0x3ee18b22...: daily NAT in / out of the bridge, net, and the cumulative locked balance.-- Lock-and-mint: the balance is NAT living on OTHER chains, not a sellable position.WITH flows AS (SELECT DATE_TRUNC('day', evt_block_time) AS day,SUM(CASE WHEN "to" = 0x3ee18b2214aff97000d974cf647e7c347e8fa585 THEN CAST(value AS DOUBLE) ELSE 0 END) AS in_nat,SUM(CASE WHEN "from" = 0x3ee18b2214aff97000d974cf647e7c347e8fa585 THEN CAST(value AS DOUBLE) ELSE 0 END) AS out_nat,SUM(CASE WHEN "to" = 0x3ee18b2214aff97000d974cf647e7c347e8fa585 THEN 1 ELSE 0 END) AS in_transfers,SUM(CASE WHEN "from" = 0x3ee18b2214aff97000d974cf647e7c347e8fa585 THEN 1 ELSE 0 END) AS out_transfersFROM erc20_ethereum.evt_TransferWHERE contract_address = 0x249130f5e2dd4cf278180c0df8273f3592ad1247AND ("to" = 0x3ee18b2214aff97000d974cf647e7c347e8fa585OR "from" = 0x3ee18b2214aff97000d974cf647e7c347e8fa585)GROUP BY 1),running AS (SELECT day, in_nat, out_nat, in_nat - out_nat AS net_nat, in_transfers, out_transfers,SUM(in_nat - out_nat) OVER (ORDER BY day ROWS UNBOUNDED PRECEDING) AS bridge_balance_natFROM flows)SELECT * FROM runningORDER BY day;