1

I'm learning CouchDB and I just read that when it comes to confict resolution, CouchDB keeps two revisions of the document, the winning one and the conflicted one. Does CouchDB keep several revisions of the same document? How can I get a specific revision?

Jonathan Hall
  • 75,165
  • 16
  • 143
  • 189
tastydb
  • 542
  • 1
  • 3
  • 13

1 Answers1

3

Yes, CouchDB keeps several revisions of a document, but not forever. In fact, you can query them using something like this (accordly to the documentation):

GET /recipes/{docid}?revs_info=true

And, if you want to retrieve an especific revision, you can do something like this:

GET /recipes/{docid}?rev={revid}

Here you have the link to the documentation.

amedina
  • 2,838
  • 3
  • 19
  • 40