I haven't tried that yet but I can... I'll get a second import running to a new db while the existing one continues.
It was the Bitcointalk forum that inspired us to create Bitcointalksearch.org - Bitcointalk is an excellent site that should be the default page for anybody dealing in cryptocurrency, since it is a virtual gold-mine of data. However, our experience and user feedback led us create our site; Bitcointalk's search is slow, and difficult to get the results you need, because you need to log in first to find anything useful - furthermore, there are rate limiters for their search functionality.
The aim of our project is to create a faster website that yields more results and faster without having to create an account and eliminate the need to log in - your personal data, therefore, will never be in jeopardy since we are not asking for any of your data and you don't need to provide them to use our site with all of its capabilities.
We created this website with the sole purpose of users being able to search quickly and efficiently in the field of cryptocurrency so they will have access to the latest and most accurate information and thereby assisting the crypto-community at large.
Loading block index...
Genesis block time: 1325369107
Genesis block bits: 1e0fffff
Genesis block nonce: 386206
Genesis block hash: 00000f2e9f8ffa3abc79a4dcbff01dcfd10f480e897ebcd50cb0c37afbe57d51
Genesis merkle root: 7dee73b5c259a6e2eb06482b289af5cb7f24476310fc80081667baf8f2f27c5b
SetBestChain: new best=00000f2e9f8ffa3abc79a4dcbff01dcfd10f480e897ebcd50cb0c37afbe57d51 height=0 work=1048577
block index 83ms
Flushed wallet.dat 24ms
askfor block 000003b4ef02c872071895b03082326f807ee202bdfc33619c3b3122620c2188 0
sending getdata: block 000003b4ef02c872071895b03082326f807ee202bdfc33619c3b3122620c2188
askfor block 000003b4ef02c872071895b03082326f807ee202bdfc33619c3b3122620c2188 1331918649000000
received block 000003b4ef02c872071895b03082326f807ee202bdfc33619c3b3122620c2188
CalculateChainWork() : New trusted block at height 93363. Last work: 9233139665732, new work: 253336966, combined: 9233393002698
SetBestChain: new best=000003b4ef02c872071895b03082326f807ee202bdfc33619c3b3122620c2188 height=93363 work=9233393002698
ProcessBlock: ACCEPTED
03/16/12 17:24:12 Flushing wallet.dat
Flushed wallet.dat 23ms
block_tx 1919268 4979880
commit
block_tx 1919269 4979881
commit
block_tx 1919270 4979882
commit
block_tx 1919271 4979883
commit
SELECT block_id FROM block WHERE block_hash LIKE '000000000661131faf72%';
SELECT cc.*, c.chain_name FROM chain_candidate cc JOIN chain c USING (chain_id) WHERE block_id = 12165;
// FAT32 filesize max 4GB, fseek and ftell max 2GB, so we must stay under 2GB
if (ftell(file) < 0x7F000000 - MAX_SIZE)
{
nFileRet = nCurrentBlockFile;
return file;
}
diff --git a/src/main.cpp b/src/main.cpp
index 9951952..2d838b7 100644
--- a/src/main.cpp
+++ b/src/main.cpp
@@ -1773,6 +1773,10 @@ FILE* OpenBlockFile(unsigned int nFile, unsigned int nBlockPos, const char* pszM
static unsigned int nCurrentBlockFile = 1;
+#ifndef BITCOIN_MAX_BLKFILE_SIZE
+#define BITCOIN_MAX_BLKFILE_SIZE 0x7F000000
+#endif
+
FILE* AppendBlockFile(unsigned int& nFileRet)
{
nFileRet = 0;
@@ -1784,7 +1788,7 @@ FILE* AppendBlockFile(unsigned int& nFileRet)
if (fseek(file, 0, SEEK_END) != 0)
return NULL;
// FAT32 filesize max 4GB, fseek and ftell max 2GB, so we must stay under 2GB
- if (ftell(file) < 0x7F000000 - MAX_SIZE)
+ if (ftell(file) < BITCOIN_MAX_BLKFILE_SIZE - MAX_SIZE)
{
nFileRet = nCurrentBlockFile;
return file;
diff --git a/Abe/abe.py b/Abe/abe.py
index 1982434..4811e01 100755
--- a/Abe/abe.py
+++ b/Abe/abe.py
@@ -92,6 +92,8 @@ HEIGHT_RE = re.compile('(?:0|[1-9][0-9]*)\\Z')
HASH_PREFIX_RE = re.compile('[0-9a-fA-F]{0,64}\\Z')
HASH_PREFIX_MIN = 6
+ADDRESS_HISTORY_ROWS_MAX = 500 # XXX hardcoded limit
+
NETHASH_HEADER = """\
blockNumber: height of last block in interval + 1
time: block time in seconds since 0h00 1 Jan 1970 UTC
@@ -930,12 +932,13 @@ class Abe:
count[txpoint['is_in']] += 1
txpoints = []
- rows = []
- rows += abe.store.selectall("""
+ max_rows = ADDRESS_HISTORY_ROWS_MAX
+ in_rows = abe.store.selectall("""
SELECT
b.block_nTime,
cc.chain_id,
b.block_height,
+ block_tx.tx_pos,
1,
b.block_hash,
tx.tx_hash,
@@ -949,13 +952,22 @@ class Abe:
JOIN txout prevout ON (txin.txout_id = prevout.txout_id)
JOIN pubkey ON (pubkey.pubkey_id = prevout.pubkey_id)
WHERE pubkey.pubkey_hash = ?
- AND cc.in_longest = 1""",
- (dbhash,))
- rows += abe.store.selectall("""
+ AND cc.in_longest = 1
+ ORDER BY
+ b.block_nTime,
+ cc.chain_id,
+ b.block_height,
+ block_tx.tx_pos,
+ txin.txin_pos
+ LIMIT ?""",
+ (dbhash, max_rows + 1))
+ truncated = in_rows[max_rows] if len(in_rows) > max_rows else None
+ out_rows = abe.store.selectall("""
SELECT
b.block_nTime,
cc.chain_id,
b.block_height,
+ block_tx.tx_pos,
0,
b.block_hash,
tx.tx_hash,
@@ -968,11 +980,41 @@ class Abe:
JOIN txout ON (txout.tx_id = tx.tx_id)
JOIN pubkey ON (pubkey.pubkey_id = txout.pubkey_id)
WHERE pubkey.pubkey_hash = ?
- AND cc.in_longest = 1""",
- (dbhash,))
+ AND cc.in_longest = 1""" + ("""
+ AND (b.block_nTime < ? OR
+ (b.block_nTime = ? AND
+ (cc.chain_id < ? OR
+ (cc.chain_id = ? AND
+ (b.block_height < ? OR
+ (b.block_height = ? AND
+ block_tx.tx_pos <= ?))))))"""
+ if truncated else "") + """
+ ORDER BY
+ b.block_nTime,
+ cc.chain_id,
+ b.block_height,
+ block_tx.tx_pos,
+ txout.txout_pos
+ LIMIT ?""",
+ (dbhash,
+ truncated[0], truncated[0], truncated[1], truncated[1],
+ truncated[2], truncated[2], truncated[3], max_rows + 1)
+ if truncated else
+ (dbhash, max_rows + 1))
+
+ if len(out_rows) > max_rows:
+ if truncated is None or truncated > out_rows[max_rows]:
+ truncated = out_rows[max_rows]
+ if truncated:
+ truncated = truncated[0:3]
+
+ rows = in_rows + out_rows
rows.sort()
for row in rows:
- nTime, chain_id, height, is_in, blk_hash, tx_hash, pos, value = row
+ if truncated and row >= truncated:
+ break
+ (nTime, chain_id, height, tx_pos,
+ is_in, blk_hash, tx_hash, pos, value) = row
txpoint = {
"nTime": int(nTime),
"chain_id": int(chain_id),
@@ -1008,7 +1050,11 @@ class Abe:
body += abe.short_link(page, 'a/' + address[:10])
- body += ['Balance: '] + format_amounts(balance, True)
+ body += ['']
']
+ if truncated:
+ body += ['Results truncated
+ else:
+ body += ['Balance: '] + format_amounts(balance, True)
for chain_id in chain_ids:
balance[chain_id] = 0 # Reset for history traversal.
chain_name block_version
Bitchip 1
Bitcoin 1
Bitcoin Testnet 1
Coiledcoin 1
Coiledcoin 1048577
Coiledcoin 1048833
Devcoin 1
Devcoin 196609
Devcoin 262145
Devcoin 262401
Fairbrix 1
GeistGeld 1
GeistGeld 257
i0coin 1
i0coin 131073
i0coin 131329
Ixcoin 1
Ixcoin 196609
Ixcoin 196865
Liquidcoin 1
Litecoin 1
Namecoin 1
Namecoin 65537
Namecoin 65793
Rucoin 1
Rucoin 196609
Rucoin 458753
Tenebrix 1