Abhishek kumar
unread,Oct 20, 2011, 2:09:52 AM10/20/11Sign in to reply to author
Sign in to forward
You do not have permission to delete messages in this group
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to mongodb-user
I have to update one of my collection, which is multi document update
Let collection "A"
A: has fields
{"_id", "field1", "field2", "field3"} // I needed to add
field3 in below update() if its not present or just update if its
present
basciDBObject.put("field1","field_value")
updateDate.put("field3","filed_value")
What I did
collection.update(basicDBObject,updateDate,false,true);
On running the command mongo is telling:
multi update only works with $ operators
Kindly help, what am I missing