Query editor
-- This query used incompatible data types from Dune SQL alpha and may need to be updated.-- More details can be found on https://dune.com/docs/query/dunesql-changes/with decodes as (SELECT--types to hex here https://dune.com/queries/1981638?d=11--uncaught types filtering here https://dune.com/queries/1981648?d=11row_number() OVER (order by t.block_height asc, t.index asc) as ordinal_number,from_utf8(from_hex(--get the content type hashsubstr(hex, position('2270223a20226272632d323022' in hex),position('7d6821' in hex)-position('2270223a20226272632d323022' in hex) --start from portion where standard ends)))) as test, from_utf8(from_hex(--get the content type hashsubstr(hex, regexp_position(hex,'0063036f72640101') +18 --start from portion where standard ends, bytearray_to_integer(0x || substr(hex,regexp_position(hex,'0063036f72640101') +16, 2))*2 --get bytes pushed as content type))) --convert from hex to utf8 againas content_type, concat('<a href="https://ordinals.com/inscription/', substr(t.id,3) || 'i0', '" target = "_blank">', substr(t.id,3) || 'i0', '</a>') as inscription, output_value, t.block_time as mint_time, t.block_height, t.size, t.virtual_size, t.fee*1e8 as fee, t.fee*1e8/t.virtual_size as sat_per_vbyte, t.output[1].script_pub_key.address as minter_address, t.index, t.id as tx_idFROM bitcoin.transactions twhere t.block_height > 767429AND t.hex LIKE '%0063036f726401%'and t.hex LIKE '%2270223a20226272632d323022%' -- OP_FALSE (0x00) OP_IF (0x63) OP_PUSHBYTES3 (0x03) "ord" (0x6f7264) OP_1 (0x01) https://docs.ordinals.com/inscriptions.html-- AND t.input[1].witness_data[2] LIKE '%0063036f726401%' AND t.input[1].type = 'witness_v1_taproot' thenthis doesn't wwhenk because of array length checksorder by ordinal_number desc),formatted as (selectcase when op = 'deploy' thencase when substr(test, position('"max"' in test)+8,position('"lim"' in test)-13-position('"max"' in test)) = '' then 0else cast(substr(test, position('"max"' in test)+8,position('"lim"' in test)-13-position('"max"' in test)) as integer)endelse 0end as supply,case when op = 'deploy' thencast(substr(test, position('"lim"' in test)+8,length(substr(test, position('"lim"' in test)+8))-2) as integer)else 0end as max_mint,