Bitcoin Forum
April 19, 2024, 12:37:20 PM *
News: Latest Bitcoin Core release: 26.0 [Torrent]
 
   Home   Help Search Login Register More  
Pages: [1]
  Print  
Author Topic: whats is best collation to store bitcoin WIF key and bitcoin address in mysql ?  (Read 325 times)
btctousd81 (OP)
Sr. Member
****
Offline Offline

Activity: 434
Merit: 270


View Profile WWW
September 01, 2017, 04:57:06 AM
 #1

i need to know which collation in mysql is best to keep the size as low as possible so that the db size will be smaller and queries will be quicker.

i am currently using utf8_unicode_ci, but i read ascii stores more data in less space.

i want to lower db size so it can be fit in RAM.

so what are you guys using ?


thanks

Transactions must be included in a block to be properly completed. When you send a transaction, it is broadcast to miners. Miners can then optionally include it in their next blocks. Miners will be more inclined to include your transaction if it has a higher transaction fee.
Advertised sites are not endorsed by the Bitcoin Forum. They may be unsafe, untrustworthy, or illegal in your jurisdiction.
1713530240
Hero Member
*
Offline Offline

Posts: 1713530240

View Profile Personal Message (Offline)

Ignore
1713530240
Reply with quote  #2

1713530240
Report to moderator
1713530240
Hero Member
*
Offline Offline

Posts: 1713530240

View Profile Personal Message (Offline)

Ignore
1713530240
Reply with quote  #2

1713530240
Report to moderator
elbandi
Hero Member
*****
Offline Offline

Activity: 525
Merit: 529


View Profile
September 02, 2017, 05:41:47 PM
 #2

you can decode base58 to hex, and store the hex as binary.
btctousd81 (OP)
Sr. Member
****
Offline Offline

Activity: 434
Merit: 270


View Profile WWW
September 02, 2017, 05:51:52 PM
 #3

you can decode base58 to hex, and store the hex as binary.

i still dont get it., what do you mean by decode base58 to hex ?

do i have tp decode both WIF and bitcoin address ? and store as binary ?

what charset should i use ?

can i later search directly by using bitcoin address ?


thanks

elbandi
Hero Member
*****
Offline Offline

Activity: 525
Merit: 529


View Profile
September 02, 2017, 06:01:45 PM
 #4

you can decode base58 to hex, and store the hex as binary.

i still dont get it., what do you mean by decode base58 to hex ?

do i have tp decode both WIF and bitcoin address ? and store as binary ?

what charset should i use ?

can i later search directly by using bitcoin address ?


thanks
you have an address, like 1QCkaDkCDAtsxG9LrLDbPrSne7q3hM3qm3 decode base58, you get: 00FE83D76016CF60187F978ACECB3480086BDD6443A1B813CA
you can store this hex (as binary) in mysql: https://dev.mysql.com/doc/refman/5.5/en/blob.html
btctousd81 (OP)
Sr. Member
****
Offline Offline

Activity: 434
Merit: 270


View Profile WWW
September 02, 2017, 06:03:51 PM
 #5

you can decode base58 to hex, and store the hex as binary.

i still dont get it., what do you mean by decode base58 to hex ?

do i have tp decode both WIF and bitcoin address ? and store as binary ?

what charset should i use ?

can i later search directly by using bitcoin address ?


thanks
you have an address, like 1QCkaDkCDAtsxG9LrLDbPrSne7q3hM3qm3 decode base58, you get: 00FE83D76016CF60187F978ACECB3480086BDD6443A1B813CA
you can store this hex (as binary) in mysql: https://dev.mysql.com/doc/refman/5.5/en/blob.html


okie, this is new., i am looking in to it,

thanks

looks like i can then decode WIF key too.

Pages: [1]
  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!