How is Blockchain a distributed database?

+4 votes

In most places blockchain is cited as a distributed database. Does it mean we can store any type of data in blockchain like audio, video, pdf?

Mar 26, 2018 in Blockchain by Perry
• 16,450 points

edited Mar 26, 2018 by Perry 129 views

5 answers to this question.

Your answer

Your name to display (optional):
Privacy: Your email address will only be used for sending these notifications.
+2 votes
Best answer

Think of blockchain as a relatively slow, very expensive database that provides excellent resistance to hacking and corruption. It's a Write-Once, Read Mostly (WORM) system.

You absolutely could store any data you want in a hypothetical blockchain. The practical limits are, you don't want to store very large chunks of data (so, not video); you probably don't want to store frequently changing data (so, not a thesis paper you're revising) -- unless it's important somehow to record every single change forever.

Because, its other feature is, once something is written to a blockchain, it's there forever.

Need to fix a typo? Then you add a new record with a correction.

Need to delete a record? Too bad, you can't. Best you can do is enter a new record saying that the record you wish to delete is "obsolete" or "repudiated" or "no longer valid" or "should be considered as deleted."

In short, it's wise to treat your blockchain as a permanent record.

  1. Slow: the Bitcoin blockchain runs about 3 transactions per second (tps) and the Ethereum blockchain runs about 30 tps.
  2. Expensive: the Bitcoin blockchain cost an average of US$ 8.22 per transaction in November 2017
answered Mar 26, 2018 by Christine
• 15,790 points

selected Aug 3, 2018 by Omkar
+1 vote

Yes, it is possible. The simplest way would be to define a contract with two attributes, an address used for access control (so that only an account that you control can write to the contract) and a byte array for the actual storage container:

contract Storage {

   address owner = 0xdeadbeef...; // <= define the address you control (have the private key to)

   bytes32[] storageContainer;

   function pushByte(bytes32 b) {
      storageContainer.push(b);
   }

}

You don't really need a getter method as it is sufficient to synchronize with the block chain in order to retrieve the data stored in the contract.

answered Oct 11, 2018 by Sabina
+1 vote

Systems like StorjSiaFilecoin, and Bittorrent break files up into little pieces and store them in computers all over the Internet. They all use technologies commonly used in blockchain systems (merkle trees, hashes, digital signatures). None of them are actually blockchains.

answered Oct 11, 2018 by Suraj
+1 vote

You can’t store digital documents on the blockchain per-se. If you mean to store in the sense of Dropbox then no, but there are a few companies who use the blockchain in order to support file storage.

answered Oct 11, 2018 by Donut
+1 vote

What you can do though is store a file and hash it. That hash is what is saved in the blockchain. You upload a file, the blockchain takes that file and uses a unique algorithm to generate a hash. Although you can’t retrieve the file because of the nature of hashes, which is a one way encryption, it can only be used as a digital stamp as to say “This file was uploaded”.

answered Oct 11, 2018 by Firoz

Related Questions In Blockchain

0 votes
1 answer

How secure is to implement blockchain at a smaller scale??

Blockchain relies on the number of nodes ...READ MORE

answered Apr 18, 2018 in Blockchain by Perry
• 16,450 points
16 views
0 votes
1 answer

In a Blockchain, how difficult is it to modify the third to last block?

Technically, it's not difficult at all, all ...READ MORE

answered Apr 20, 2018 in Blockchain by Christine
• 15,790 points
44 views
+1 vote
1 answer

Is it possible to store blockchain in a sql or no-sql database?

Currently, following are the options to store ...READ MORE

answered Apr 20, 2018 in Blockchain by Perry
• 16,450 points

edited Aug 9, 2018 by Omkar 45 views
0 votes
1 answer

How a transaction validity is verified in blockchain?

Blockchain has the records the of all ...READ MORE

answered May 11, 2018 in Blockchain by Johnathon
• 9,070 points
32 views
0 votes
1 answer

Truffle tests not running after truffle init

This was a bug. They've fixed it. ...READ MORE

answered Sep 11, 2018 in Blockchain by Christine
• 15,790 points
81 views
0 votes
1 answer
+1 vote
1 answer

How is a smart contract stored on a Blockchain?

Smart contract template and transaction events are ...READ MORE

answered Apr 4, 2018 in Blockchain by Christine
• 15,790 points
110 views
+1 vote
8 answers

How is Blockchain a linked list?

Blockchain is similar to Single Linked List ...READ MORE

answered Aug 3, 2018 in Blockchain by Omkar
• 66,910 points
1,322 views

© 2018 Brain4ce Education Solutions Pvt. Ltd. All rights Reserved.
"PMP®","PMI®", "PMI-ACP®" and "PMBOK®" are registered marks of the Project Management Institute, Inc. MongoDB®, Mongo and the leaf logo are the registered trademarks of MongoDB, Inc.