Intellipaat Back

Explore Courses Blog Tutorials Interview Questions
0 votes
2 views
in Blockchain by (12.7k points)

If a chaincode A stores a variable V to the World State can this variable V be accessed by another chaincode B?

In other words, are variables in the World State access protected?

If it is not possible, how can I make chaincode B read the variables from chaincode A (I need it for my use case)?

1 Answer

0 votes
by (29.5k points)

No, variables stored by some chaincode A can only be accessed by the same chaincode A.

In case you want to to do something like that you can try to  invoke/query chaincode A from chaincode B

31k questions

32.8k answers

501 comments

693 users

Browse Categories

...