Updating multiple documents using Java couchbase SDK

Viewed 273

I am using java Couchbase sdk in my application. I want to update same path with same values for multiple documents. For example there is a key X with value Y in all these documents. I want to update the Key X to have the value Z.

I am using the Async bucket's query method and the query that I am using looks like this-

UPDATE default USE KEYS ["a","b","c"] SET X=Z

default is the bucket name

a,b,c are the document keys that I want to update.

My question here is does the sdk guarantees that either all of these keys will be updated or none of them. How do I know if all the documents were updated correctly?

1 Answers
Related