user1878: I right clicked the transaction history in the QT client and pasted in the TxID below.
Q1
In the following test, can anyone explain what the purpose of the suffix -000 is and what it's used for?
gettransaction 54b9be14443b152b02ed0b18d27504631cccfa84ce9ada03f9558fbb85b6129c-000

Q2
Why doesn't a raw transaction support the same transaction ID format as the previous command?  (I need to remove the -000 characters)
getrawtransaction 54b9be14443b152b02ed0b18d27504631cccfa84ce9ada03f9558fbb85b6129c-000
ERROR: parameter 1 must be hexadecimal string

Q3
When I enable index=1 in bitcoin.conf and reindex, why can't I call GetTransaction for transactions not in my wallet?  I would like JSON friendly results

user208: Q1: A ledger entry in the wallet view corresponds to a single output of a transaction. The suffix is there to distinguish which output of the transaction is used. It's a bit of strange choice to format it that way; in most places, ':' is used as a separator.
Q2: getrawtransaction queries the memory pool, the set of unspent transaction outputs and the blockchain (if txindex is enabled) for a transaction. It doesn't query a single output, so you pass in just the hexadecimal identifier. You can query individual unspent transaction outputs using the gettxout command (which takes a txid + the output index as separate arguments). You can pass an extra 1 as argument to getrawtransaction to have it decoded, instead of just the raw hex. decoderawtransaction can do this for arbitrary hex-encoded raw transactions. Perhaps this is the answer to Q3.
Q3: gettransaction is a wallet RPC. It cannot operate on anything else, as it needs the higher abstraction layer. It computes debit/credit and fee, which requires identifying which outputs are from/to you, and which are change. This requires knowing what keys belong to you. It does not query the blockchain, but you can use 'getrawtransaction [txid] 1' to get a decoded form of blockchain transactions (with txindex enabled).

1878: <p>I right clicked the transaction history in the QT client and pasted in the TxID below.</p>

<p><strong>Q1</strong></p>

<p>In the following test, can anyone explain what the purpose of the suffix <code>-000</code> is and what it's used for?</p>

<pre><code>gettransaction 54b9be14443b152b02ed0b18d27504631cccfa84ce9ada03f9558fbb85b6129c-000
</code></pre>

<p><strong>Q2</strong></p>

<p>Why doesn't a raw transaction support the same transaction ID format as the previous command?  (I need to remove the -000 characters)</p>

<pre><code>getrawtransaction 54b9be14443b152b02ed0b18d27504631cccfa84ce9ada03f9558fbb85b6129c-000
ERROR: parameter 1 must be hexadecimal string
</code></pre>

<p><strong>Q3</strong></p>

<p>When I enable <code>index=1</code> in bitcoin.conf and reindex, why can't I call <code>GetTransaction</code> for transactions not in my wallet?  I would like JSON friendly results</p>
 208: <p>Q1: A ledger entry in the wallet view corresponds to a single <em>output</em> of a transaction. The suffix is there to distinguish which output of the transaction is used. It's a bit of strange choice to format it that way; in most places, ':' is used as a separator.</p>

<p>Q2: <code>getrawtransaction</code> queries the memory pool, the set of unspent transaction outputs and the blockchain (if <code>txindex</code> is enabled) for a transaction. It doesn't query a single output, so you pass in just the hexadecimal identifier. You can query individual unspent transaction outputs using the <code>gettxout</code> command (which takes a txid + the output index as separate arguments). You can pass an extra 1 as argument to getrawtransaction to have it decoded, instead of just the raw hex. <code>decoderawtransaction</code> can do this for arbitrary hex-encoded raw transactions. Perhaps this is the answer to Q3.</p>

<p>Q3: <code>gettransaction</code> is a wallet RPC. It cannot operate on anything else, as it needs the higher abstraction layer. It computes debit/credit and fee, which requires identifying which outputs are from/to you, and which are change. This requires knowing what keys belong to you. It does not query the blockchain, but you can use '<code>getrawtransaction</code> [txid] 1' to get a decoded form of blockchain transactions (with <code>txindex</code> enabled).</p>
