Bitcoin Forum
April 25, 2024, 11:24:52 AM *
News: Latest Bitcoin Core release: 27.0 [Torrent]
 
   Home   Help Search Login Register More  
Pages: « 1 [2]  All
  Print  
Author Topic: Something strange here....  (Read 1951 times)
jerethdaminer
Member
**
Offline Offline

Activity: 84
Merit: 10


View Profile
May 12, 2013, 03:35:35 PM
 #21

thanks for explaining that seems wierd but if it works, so if my pool payouts keep going to one address then its still keeping the amounts seperate?

so how would you merge small amounts back into a single input output thing for spending
1714044292
Hero Member
*
Offline Offline

Posts: 1714044292

View Profile Personal Message (Offline)

Ignore
1714044292
Reply with quote  #2

1714044292
Report to moderator
1714044292
Hero Member
*
Offline Offline

Posts: 1714044292

View Profile Personal Message (Offline)

Ignore
1714044292
Reply with quote  #2

1714044292
Report to moderator
1714044292
Hero Member
*
Offline Offline

Posts: 1714044292

View Profile Personal Message (Offline)

Ignore
1714044292
Reply with quote  #2

1714044292
Report to moderator
"You Asked For Change, We Gave You Coins" -- casascius
Advertised sites are not endorsed by the Bitcoin Forum. They may be unsafe, untrustworthy, or illegal in your jurisdiction.
1714044292
Hero Member
*
Offline Offline

Posts: 1714044292

View Profile Personal Message (Offline)

Ignore
1714044292
Reply with quote  #2

1714044292
Report to moderator
1714044292
Hero Member
*
Offline Offline

Posts: 1714044292

View Profile Personal Message (Offline)

Ignore
1714044292
Reply with quote  #2

1714044292
Report to moderator
1714044292
Hero Member
*
Offline Offline

Posts: 1714044292

View Profile Personal Message (Offline)

Ignore
1714044292
Reply with quote  #2

1714044292
Report to moderator
DeathAndTaxes
Donator
Legendary
*
Offline Offline

Activity: 1218
Merit: 1079


Gerald Davis


View Profile
May 12, 2013, 03:51:14 PM
 #22

You don't.  You just spend them.
Terk
Hero Member
*****
Offline Offline

Activity: 616
Merit: 522



View Profile
May 12, 2013, 03:52:35 PM
 #23

You don't have to merge them to spend. Your client will automatically combine multiple outputs to create a transaction. So in the previous example where you have outputs: 10 BTC, 30 BTC and 60 BTC; if you want to send 80 BTC, your client will take 60 BTC and 30 BTC outputs to create a 90 BTC transaction: 80 BTC will go to the address you want to send to, and 10 BTC will go back to your wallet to one of your change addresses. You don't really need to think about these things as it's handled automatically under the hood.

jerethdaminer
Member
**
Offline Offline

Activity: 84
Merit: 10


View Profile
May 12, 2013, 03:56:57 PM
 #24

its just im a small time miner so i have payments of .3-.5 btc and id liketo mitigate fees as much as possible as it increases
kjj
Legendary
*
Offline Offline

Activity: 1302
Merit: 1024



View Profile
May 12, 2013, 08:37:32 PM
 #25

You can send transactions to yourself.  If you just do sendtoaddress, you won't necessarily collect the small transactions that you are hoping to collect, unless you send your entire balance to yourself.  Which isn't necessarily a good idea, by the way.

Or, you can use the raw transaction API to collect the small transactions and send them to yourself, manually.  This is a hassle, but works well, particularly once you have it scripted.

17Np17BSrpnHCZ2pgtiMNnhjnsWJ2TMqq8
I routinely ignore posters with paid advertising in their sigs.  You should too.
DeathAndTaxes
Donator
Legendary
*
Offline Offline

Activity: 1218
Merit: 1079


Gerald Davis


View Profile
May 12, 2013, 08:45:16 PM
 #26

its just im a small time miner so i have payments of .3-.5 btc and id liketo mitigate fees as much as possible as it increases

Make the payment threshold from your pool the largest you are comfortable with.  Each tx is a separate unspent output.
Nancarrow
Hero Member
*****
Offline Offline

Activity: 492
Merit: 500


View Profile
May 12, 2013, 08:50:53 PM
 #27

thanks for explaining that seems wierd but if it works, so if my pool payouts keep going to one address then its still keeping the amounts seperate?

I don't think anyone addressed this bit. The answer is no, the amounts aren't kept separate. It's only when an address is an INPUT that its entire amount gets spent. You can have several transactions send to the same address, and the address only stores the total balance (though the blockchain keeps a record of each transaction, and so will your client if you can be arsed to look, which I usually can't).

If I've said anything amusing and/or informative and you're feeling generous:
1GNJq39NYtf7cn2QFZZuP5vmC1mTs63rEW
DeathAndTaxes
Donator
Legendary
*
Offline Offline

Activity: 1218
Merit: 1079


Gerald Davis


View Profile
May 13, 2013, 04:14:01 AM
 #28

thanks for explaining that seems wierd but if it works, so if my pool payouts keep going to one address then its still keeping the amounts seperate?

I don't think anyone addressed this bit. The answer is no, the amounts aren't kept separate. It's only when an address is an INPUT that its entire amount gets spent. You can have several transactions send to the same address, and the address only stores the total balance (though the blockchain keeps a record of each transaction, and so will your client if you can be arsed to look, which I usually can't).


Not correct.

The blockchain ONLY cares about inputs and outputs.  Each tx creates separate outputs and uses older unspent outputs (making them spent) as inputs.  So if one receives 1 BTC, 0.5 BTC and 0.2 BTC at address X.  The amounts are "seperate".  Nowhere at the protocol level is there "1.7 BTC at address x".  There are three distinct unspent outputs to address X in the amounts of 1.0, 0.5 & 0.2 BTC.  One can create a tx spending one or more of them if one has the private key for address X.


There is no such thing as "total value" at an address at the protocol level.  Now your client will scan the blockchain and give you the total but that is merely an abstraction.  When your wallet shows "balance: 1.000 BTC" what is really means is that "as of the current block I have scanned the entire blockchain and located in the blockchain unspent outputs for addresses that I have the corresponding private key and the sum of those unspent outputs is 1.000 BTC"
jerethdaminer
Member
**
Offline Offline

Activity: 84
Merit: 10


View Profile
May 13, 2013, 10:29:27 PM
 #29

ok thanks seems complex but if its all back end stuff guess its fine
Pages: « 1 [2]  All
  Print  
 
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.19 | SMF © 2006-2009, Simple Machines Valid XHTML 1.0! Valid CSS!