I have refereed below link for Querying into the ledger in Hyper-ledger Fabric Network :
http://hyperledger-fabric.readthedocs.io/en/release/write_first_app.html
In above link, they have given git-hub link in which I have done all the steps like, - start the network - run the node scripts for querying to the ledger like invoke.js, query.js
But in that scripts they have provided one example of Car, in which they called different functions for querying all car, adding car and so on.
I have also run the marbles demo mentioned in below link : https://github.com/IBM-Blockchain/marbles
In this link, they have run the same network named "fabric-samples" which I have mentioned first link of this question.
So, now I want to run queries for marbles and for that I have changed the query.js and in that I have give chaincode id as "marbles" and give function name "readMarble" and pass the marble name in argument.
And then I have node query.js so it gives an errors as below :
Store path:/home/riyasoni/riya/blockchain/workspace/fabric-samples/fabcar/hfc-key-store Successfully loaded user1 from persistence error: [client-utils.js]: sendPeersProposal - Promise is rejected: Error: 2 UNKNOWN: chaincode error (status: 500, message: Received unknown invoke function name - 'readMarble') at new createStatusError (/home/riyasoni/riya/blockchain/workspace/fabric-samples/fabcar/node_modules/grpc/src/client.js:65:15) at /home/riyasoni/riya/blockchain/workspace/fabric-samples/fabcar/node_modules/grpc/src/client.js:568:15 Query has completed, checking results error from query = { Error: 2 UNKNOWN: chaincode error (status: 500, message: Received unknown invoke function name - 'readMarble') at new createStatusError (/home/riyasoni/riya/blockchain/workspace/fabric-samples/fabcar/node_modules/grpc/src/client.js:65:15) at /home/riyasoni/riya/blockchain/workspace/fabric-samples/fabcar/node_modules/grpc/src/client.js:568:15 code: 2, metadata: Metadata { _internal_repr: {} }, details: 'chaincode error (status: 500, message: Received unknown invoke function name - \'readMarble\')' }
So, can anyone suggest me that how can querying to ledger for marbles demo related functions and transaction?