title: Mongo regex query in java
body: <p>How to write this query in java.</p>
  <pre><code>db.getCollection('recipe_qmeshm_enumerations').find({
             &quot;values.value&quot;:/^\QbuTTer\E$/i
     })
  </code></pre>
  <p>I am trying to write like this but it's not giving any result.</p>
  <pre><code>Criteria criteria2 = new Criteria().where(&quot;values.value&quot;).regex(&quot;/^\QbuTTer\E$/i&quot;);
      
  Query query2 = new Query();
  
  query2.addCriteria(criteria2);
  </code></pre>