title: With Mongoid, can I "update_all" to push a value onto an array field for multiple entries at once?
body: <p>Using Mongoid, is it possible to use "update_all" to push a value onto an array field for all entries matching a certain criteria?</p>
  
  <p>Example:</p>
  
  <pre><code>class Foo
    field :username
    field :bar, :type =&gt; Array
  
    def update_all_bars
      array_of_names = ['foo','bar','baz']
      Foo.any_in(username: foo).each do |f|
        f.push(:bar,'my_new_val')
      end
    end
  end
  </code></pre>
  
  <p>I'm wondering if there's a way to update all the users at once (to push the value 'my_new_val' onto the "foo" field for each matching entry) using "update_all" (or something similar) instead of looping through them to update them one at a time. I've tried everything I can think of and so far no luck.</p>
  
  <p>Thanks</p>