igorbarinov / opreturnio

Analytics on top of op_return data from the bitcoin blockchain

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

opreturnio

Analytics on top of op_return data from the bitcoin blockchain

Preparation

Bitcoin SQL DB Node Setup

wait 8-10 hours

Queries

Get count of bitccoin transactions with OP_RETURN in output

bitcoin=# SELECT count(tx_id) from txout where encode(pk_script,'hex') LIKE '6a%';

Alter table

ALTER TABLE txout ADD pk_script_string text;

Update table

UPDATE txout SET pk_script_string = encode(pk_script,'hex');

About

Analytics on top of op_return data from the bitcoin blockchain