:: Re: [Libbitcoin] a HOWTO question
Página Inicial
Delete this message
Reply to this message
Autor: Eric Voskuil
Data:  
Para: P Perazim, libbitcoin
Assunto: Re: [Libbitcoin] a HOWTO question
On 04/06/2017 05:23 AM, P Perazim wrote:
> I have a general question about howto do something using bx.
>
> I need to select a number of unspent outputs based upon certain
> selection criteria. I presently do this by using postgres to
> generate the addresses then using bx to get the unspents, address
> by address and processing the outputs using postgres.
>
> Is there any kind of functionality in bx that would allow obtaining
> the top addresses, top activity of addresses much like some of the
> functions of blockchain.info?



Hi Perazim,

To perform a top activity query would require the creation of an
additional index or a scan of the full history index.

The server's history table indexes a record for each occurrence of any
address hash by the output or input (i.e. activity) of the occurrence.
But the table has no index for number of occurrences.

Providing an top(N) index for this is not a performance or even
storage issue, would just take some work. Would just need to update an
index of N entries each time a record is stored. The query from that
would be straightforward.

I could offer more help if you could be more specific about the
queries you require.

e