0
I need to track an amount of Bitcoins in a database. Is a UINT64 sufficient?
I'd rather not deal with floating point types, and the rounding errors they end with.
0
I need to track an amount of Bitcoins in a database. Is a UINT64 sufficient?
I'd rather not deal with floating point types, and the rounding errors they end with.
6
yes, UINT64 is sufficient, which is in fact how the Bitcoin protocol works internally. The conversion factor from UINT64 to BTC is 1.0e8.
Not using floating point numbers is a very good idea indeed.
1The title is catchy but nonsensical. I am guessing you are trying to keep track of an amount of bitcoins (e.g. BTC 3.01329) but that is not clear from your wording – Nate Eldredge – 2014-08-12T21:44:29.797
@NateEldredge it's tagged development, yes.. I want to know that the max value in a Tx is defined to be 64 bits. I made it clearer – goodguys_activate – 2014-08-12T21:47:16.440