MongoDB Java – Update every sub-array element using another field value
I have an existing collection, containing several documents: [{ "_id": "1", "someArray": [ { "_id": "1.1" "color": "RED" }, { "_id": "1.2" "color": "GREEN" }, { "_id": "1.3" "color": "GREEN" } ] }, { "_id": "2", "someArray": [ { "_id":…