title: Custom method for update query with spring data MongoRepository
body: <p>I am using  org.springframework.data.mongodb.repository.MongoRepository. I have written some custom method like below,</p>
  
  <pre><code>public interface DocRepository extends MongoRepository&lt;Doc, String&gt; {
       Doc findByDocIdAndAssignmentId(final String docId, final String assignemtId);
  }
  </code></pre>
  
  <p>How can I write a custom method which update all entries when meeting a criteria. </p>
  
  <p>For example set document tilte field to "abc" if assignment id is "xyz"?</p>