during the last couple of days several people send me a pm regarding the mysql blockchain copy i work on so i decided to make the access to it public.
the intended use for it is to have access to blockchain data within a mysql database to develop applications based on it.
since this tool currently is a php script which populates a mysql database with blockchain data by api queries to the wallet a normal user may not have any use for it since web developers get enabled to create content based on blockchain data in their known development environment
here you get the mysql schema dump:
http://pastebin.com/8f8ML2jEhere you get the php script to populuate the database with:
http://pastebin.com/Kx7uyH7Gin the schema dump you may require to adjust the security definer if your mysql instance does not know the user root (on windows).
in the php script you have to adjust the db login variables to match to your database and maybe set the wallet address which is currently assumed to run on localhost.
if everything works like expected the php script console output shall look like this if startet:
wallet blockchain height: 99696
we start at block: 99690
tx ids: 17 block: 99691 scoop: 2976 target: 1573200 reward: 6302 miner: BURST-L2V2-AXNC-VW9G-9XBWM time: 24123845
tx ids: 8 block: 99692 scoop: 1053 target: 1497780 reward: 6302 miner: BURST-42JY-E6TZ-885E-AZ9HK time: 24124043
tx ids: 4 block: 99693 scoop: 1532 target: 1555930 reward: 6302 miner: BURST-3N7E-CX8T-K6AM-D6Q4N time: 24124285
tx ids: 1 block: 99694 scoop: 2652 target: 1685443 reward: 6302 miner: BURST-XWEZ-N5EH-ZBFU-3QBUD time: 24125064
tx ids: 0 block: 99695 scoop: 2636 target: 1718812 reward: 6302 miner: BURST-5YBX-W97K-PEHB-C4XPX time: 24125119
you may run the php script at any time but should make sure it gets only startet once.
at the moment there is no fork detection included.
so if your wallet runs on a fork and you have forked data in your db you have to manually truncate the tables above a certain height after switching back to the main chain. if anyone has a simple idea how to detect forks i can add this feature.