New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Map/Reduce query not working on partitioned non-replicated database #8405
Comments
hey @Karalix I assume they are "todaybegin:IDENTIFIER"? |
Sure, they are typicaly in the form And one the views I am trying to use is formatted like this: {
"_id": "_design/events",
"_rev": "1-9deb72b6aa08e62e8618a2426833f64e",
"views": {
[...]
"tag-list": {
"reduce": "_count",
"map": "function (doc) {\n if (doc.tags && doc.tags.length > 0) {\n for (const tag of doc.tags) {\n emit(tag, 1)\n }\n }\n}"
}
},
"language": "javascript",
"options": {
"partitioned": true
}
} |
hey @Karalix , thanks for the feedback. I truly believe that Pouchdb API has not catch up the partition db that Couchdb has. I used nano in Node.js seamlessly but haven't had the need with Pouchdb. Let me give it a try based on my node.js project. |
This issue is stale because it has been open 60 days with no activity. Remove stale label or comment or this will be closed in 7 days |
i am also facing the same issue why pouch DB is not supporting partitioned feature |
i made a pr for this, the issue has been closed accidentally by the stale bot. if a maintainer sees this, pls consider reopening. |
Issue
I have a partitioned database on my CouchDB server. I access it by giving its URL to the PouchDB constructor so PouchDB is acting only as a client. Although everything seems to work fine, when I try to use the query method to execute a view from my design document :
I get the following error :
I was a bit surprised because this error did not show up with a locally replicated database during my previous work with PouchDB. But well, it makes sense since nano has a specific method for partitioned db and when dealing with CouchDB API directly, it also always require the partition name in the following form
http://127.0.0.1:5984/databasename/_partition/event/_design/events/_view/dates
I can't find anywhere in the docs if there is an existing parameter so I can pass to set the name of the partition.
Info
The text was updated successfully, but these errors were encountered: