Bitcoin Forum
December 15, 2017, 12:58:15 AM *
News: Latest stable version of Bitcoin Core: 0.15.1  [Torrent].
 
   Home   Help Search Donate Login Register  
Pages: [1]
  Print  
Author Topic: Help me with reading blockchain transactions please  (Read 716 times)
Looser by Choice
Jr. Member
*
Offline Offline

Activity: 56


View Profile
January 25, 2013, 08:13:14 PM
 #1

Lets take this transaction for example
http://blockchain.info/tx-index/46391193/6367e35f17c0bbf8a8061dc9e231a8db650893f1ba916ff4ffeaa49421e8c76e

I sent just 0.2 BTC but for some reason it says there are 0.08 sent to one address and 0.2 to another.
From where those 0.08 come and what they have to do with my transaction?

I've seen that many times but now decided to test with my own transaction.

Is there a tutorial for reading blockchain transactions?
1513299495
Hero Member
*
Offline Offline

Posts: 1513299495

View Profile Personal Message (Offline)

Ignore
1513299495
Reply with quote  #2

1513299495
Report to moderator
1513299495
Hero Member
*
Offline Offline

Posts: 1513299495

View Profile Personal Message (Offline)

Ignore
1513299495
Reply with quote  #2

1513299495
Report to moderator
1513299495
Hero Member
*
Offline Offline

Posts: 1513299495

View Profile Personal Message (Offline)

Ignore
1513299495
Reply with quote  #2

1513299495
Report to moderator
Advertised sites are not endorsed by the Bitcoin Forum. They may be unsafe, untrustworthy, or illegal in your jurisdiction. Advertise here.
1513299495
Hero Member
*
Offline Offline

Posts: 1513299495

View Profile Personal Message (Offline)

Ignore
1513299495
Reply with quote  #2

1513299495
Report to moderator
lassdas
Legendary
*
Offline Offline

Activity: 1876


View Profile
January 25, 2013, 08:22:04 PM
 #2

You buy something for 2 bucks, hand out a $10 bill and get $8 back as change.
The same happens here, you have 1 transaction of 0.28BTC in your wallet, want to send 0.2 to someone and get 0.08 back as change.

As simple as that.
DannyHamilton
Legendary
*
Online Online

Activity: 2002



View Profile
January 25, 2013, 08:36:48 PM
 #3

With the way bitcoin works, you can't partially spend a previous output that you received.  It has to be completely spent.  So, if you receive 10 BTC all in a single transaction from someone/somewhere at an address, then that address now has a single 10 BTC output.

Later if you want to send 2 BTC to somebody, the program can use the previous 10 BTC output as an input into the transaction, and create a 2 BTC output to the address where you want to send it.  This leaves 8 BTC leftover in the transaction.  If you don't send those 8 BTC somewhere, then they become miner fees and end up in the coinbase transaction of the new block for the miner to keep.  If you don't want to give those 8 BTC away as fees to the miner, then you need to include a second output in your transaction sending the 8 BTC back to your own wallet.  As an analogy, think of pulling a $10 bill out of your pocket to pay for something that costs $2, you get $8 back in "change".

The way Bitcoin-Qt does this is to create a new bitcoin address that it doesn't tell you about and keep track of that address and the associated private key in your wallet.dat.  Since this isn't an address that you requested in the "Receive Coins" tab of the user interface, it doesn't show up in that list.  Bitcoin-Qt knows about the address since it is in the wallet.dat file, so it includes it in the balance that it shows you.  Bitcoin-Qt uses a new change address for every transaction.  So if you create 10 different transactions, each sending bitcoins somewhere, then your wallet will have used 10 different change addresses (although some of them may be empty if Bitcoin-Qt used the bitcoins associated with some of those address as inputs into other transactions.

Looser by Choice
Jr. Member
*
Offline Offline

Activity: 56


View Profile
February 14, 2013, 03:23:11 PM
 #4

aha! Great explanations guys, appreciate it! Smiley
Pages: [1]
  Print  
 
Jump to:  

Sponsored by , a Bitcoin-accepting VPN.
Powered by MySQL Powered by PHP Powered by SMF 1.1.19 | SMF © 2006-2009, Simple Machines Valid XHTML 1.0! Valid CSS!