Top "Mongodb-.net-driver" questions

The official MongoDB .NET Driver provides asynchronous interaction with MongoDB.

MongoDB FilterDefinition & IQueryable in C#

I have the following spatial FilterDefinition: var filter = Builders<MyDocument> .Filter .Near(x => x.Point, point, 1000); Is …

.net mongodb mongodb-query mongodb-.net-driver mongodb-csharp-2.0
Convert BSON to valid JSON

The BsonDocument.ToJson() method returns invalid JSON, as ObjectID() and ISODate are not valid JSON. What's the best way to …

c# .net mongodb mongodb-.net-driver bson
Initialize MongoClient with MongoClientSettings in C#

I'm trying to initialize the MongoClient from the Mongo 2.0 driver as follows: MongoClientSettings settings = new MongoClientSettings(); settings.WaitQueueSize = int.MaxValue; …

c# .net mongodb mongodb-.net-driver mongodb-csharp-2.0
Deserialize object as an interface with MongoDB C# Driver

I am developing a project that uses MongoDB (with C# driver) and DDD. I have a class (aggregate) which have …

c# mongodb mongodb-.net-driver
Suitability of MongoDB for hierarchial type queries

I have a particular data manipulation requirement that I have worked out how to do in SQL Server and PostgreSQL. …

mongodb hierarchical-data mongodb-.net-driver
Insert element into nested array in Mongodb

I have this : { "_id" : ObjectId("4fb4fd04b748611ca8da0d48"), "Name" : "Categories", "categories" : [{ "_id" : ObjectId("4fb4fd04b748611ca8…

c# mongodb insert driver mongodb-.net-driver
What is the right way to manage MongoDB connections in ASP.Net MVC?

What is the best practice for managing the MongoServer class life cycle? Should I create one and close it at …

c# asp.net asp.net-mvc mongodb mongodb-.net-driver
Deserialising polymorphic types with MongoDB C# Driver

Assume, I have a base class public class Node{ public ObjectId Id; public String nodeName; public ObjectId parentNode; } and 2 derived …

c# mongodb deserialization mongodb-.net-driver
c# - How to use DateTimeOffset in MongoDB

public class ScheduledEvent : Event { public DateTimeOffset StartDateTime { get; set; } } StartDateTime = 5/27/2013 2:09:00 AM +00:00 representing 05/26/2013 07:09 PM PST What's recorded in MongoDB: db.ScheduledEvent.…

c# mongodb mongodb-.net-driver
How do I log my queries in MongoDB C# Driver 2.0?

Just upgraded my application to the latest stable MongoDB C# Driver 2.0. During the migration, basic functionality has been broken and …

c# mongodb logging mongodb-.net-driver mongodb-csharp-2.0