Reputation:
I'm using jquery.couch.js
to write a document to my CouchDB. I've taken care of parsing the JSON data and getting the request ready. When my script actually sends the $.couch.db.saveDoc()
command, I get a 201 Created
response code for my post
request, which also includes the following:
{"ok":true,"id":"...","rev":"..."}
(where "..." is an actual UUID)
But when I check my CouchDB afterwards, no document has been created.
I've encountered this before, but it always ends up getting resolved by some other method. Basically it seems like the couch returns "ok":true
regardless of whether the document is created. The part that really gets me though is that it actually returns a generated UUID (which means that the request actually reached my CouchDB, if I'm not mistaken). So I can't figure out why the document isn't written.
Has anyone encountered this issue before?
Upvotes: 0
Views: 257
Reputation: 4441
A few things to note here...
/database/docID
) or from a view? If it's from a view then your index might not be updated yet.Upvotes: 1