【发布时间】:2021-08-24 10:14:01
【问题描述】:
我在结构中使用 couchDB 作为对等体中的状态数据库。我有一个存储在分类帐中的 json 数据
JSON 数据
"Company": {
"Associate": {
"entity": {
"name": "foo",
"role": "admin"
},
"access": [
{
"create": "allowed"
}
]
}
}
}
我必须根据 access json 对象查询数据,比如这些具有“create”、“readonly”、“delete”等值。
目前我尝试了这个,但没有任何记录出现。
{
"selector": {
"Company": {
"Associate": {
"access": {
"$elemMatch": {
"$eq": "create"
}
}
}
}
}
}
如何查询数据?
【问题讨论】:
标签: couchdb hyperledger-fabric blockchain hyperledger