helun / Ektorp

Java API for CouchDB
Apache License 2.0
300 stars 146 forks source link

querying a doc with a show function #263

Open eroux opened 7 years ago

eroux commented 7 years ago

I have the following design document:

{
  "_id": "_design/jsonld",
  "_rev": "6-1d31766f96fe194d286cc9cf8c31e5c6",
  "shows": {
    "jsonld": "function(doc, req) {\n  return toJSON(doc[\"@graph\"]);\n}"
  },
  "language": "javascript"
}

and would like to query documents according to this view. It seems impossible with the current API.

YannRobert commented 7 years ago

You're right, there is no explicit way to query a show function.

You may be able to do it by either :