How can I modify stored data in blockchain

+1 vote

How can I alter a data stored in a block.  consider this code snippet,

{
    studentId:600,
    marks:300
}

Suppose, the above code was written to include a data entry in the blockchain. Now, I want to update this marks to 400. so can i do this in a block chain. I heard that we couldn't update a bockchain

Apr 18, 2018 in Blockchain by anonymous
6,124 views

1 answer to this question.

0 votes

One of the important feature of a blockchain is immutability, which means that any transaction once recorded cannot be altered. The only way to maodify is to add the updated data in a new a new blockchain.

So, instead of the code to change the marks from 400 to 500 you should add a new point of data to the variable. Also, if you want to reduce the marks, you have to add it in a new block and save it to the variable.

answered Apr 18, 2018 by Christine
• 15,790 points

Related Questions In Blockchain

0 votes
0 answers

How I can check where the data is actually stored when we deploy blockchain?

How I can check where the data ...READ MORE

May 14, 2020 in Blockchain by Zara
• 140 points
1,033 views
0 votes
1 answer

How can i read headers of blockchain in multichain?

You could use a recent feature known ...READ MORE

answered Mar 26, 2018 in Blockchain by Perry
• 17,100 points
736 views
+1 vote
2 answers

Can I include real world data in a smart contract? If so, how?

You cant access/embed real world data using ...READ MORE

answered Jul 18, 2018 in Blockchain by sapan
1,163 views
0 votes
1 answer
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
1,923 views
+1 vote
1 answer
0 votes
1 answer

Hyperledger Sawtooth vs Quorum in concurrency and speed Ask

Summary: Both should provide similar reliability of ...READ MORE

answered Sep 26, 2018 in IoT (Internet of Things) by Upasana
• 8,620 points
1,451 views
0 votes
1 answer

How can i create a simple P2P network on a blockchain?

To develop your own cryptocurrency, you need ...READ MORE

answered Apr 20, 2018 in Blockchain by Christine
• 15,790 points
2,020 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
1,027 views
webinar REGISTER FOR FREE WEBINAR X
REGISTER NOW
webinar_success Thank you for registering Join Edureka Meetup community for 100+ Free Webinars each month JOIN MEETUP GROUP