开发者

Update Couchdb document

开发者 https://www.devze.com 2023-04-09 10:51 出处:网络
I have a Couchdb document id and revision id and I would like to update the document. How can I achieve this using CouchRest?

I have a Couchdb document id and revision id and I would like to update the document. How can I achieve this using CouchRest?

I have tried including开发者_运维知识库 "_rev" in "put" as suggested somewhere but that doesn't work. This is what I've tried so far:

 CouchRest.put('connection/db/docid',{"_rev": "id"},"Name": "XVZ"})


I advise you to read this doc : http://guide.couchdb.org/draft/tour.html#first It might make couchdb clearer!

PS : You must specify id and rev to make it work.

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号