Yes. It's mongo limitation :( There is no way to multiple update
But your solution works. Thanks.
On 9 июн, 20:38, Jason Liszka <
jlis...@foursquare.com> wrote:
> Looks like a mongo limitation around setting fields in an array of objects. Can you run your query in the mongo console directly to see if that's it?
>
> User where(_.id eqs "userId") modify(_.clans.subfield(_.isAdmin) setTo
> Full(true)) toString
>
> will give you the shell command to run.
>
> You'll probably have more luck setting the field on a single object in the array. Try
>
> User where(_.id eqs "userId")
> and (_.clans somecondition)
> modify(_.clans.$.subfield(_.isAdmin) setTo
> Full(true))
>