I am using MongoDB 2, and I want to update multiple documents and upsert a value like processed:true
into the collection. But MongoDB c# api only allows us to
UpdateFlags is an enum in the C# driver that will let you specify both at once. Just like any other flags enum, you do this by bit "or"ing.
var flags = UpdateFlags.Upsert | UpdateFlags.Multi;
You can read the docs on enums here (http://msdn.microsoft.com/en-us/library/cc138362.aspx) paying special attention to the section on Enumeration Types as Bit Flags