Skip to content

Settings and activity

2 results found

  1. 51 votes
    Vote

    We're glad you're here

    Please sign in to leave feedback

    Signed in as (Sign out)
    You have left! (?) (thinking…)
    How important is this to you?

    We're glad you're here

    Please sign in to leave feedback

    Signed in as (Sign out)
    An error occurred while saving the comment
    Anonymous commented  · 

    I have had an excellent experience working with MongoDB from LINQPad. Try this:
    1. Open Query Properties -> Additional References
    Add a reference to the mongocsharpdriver NuGet package( https://www.nuget.org/packages/mongocsharpdriver/1.10.0)
    2. Go to Additional Namespace Imports and add a reference to MongoDB.Driver

    3. Then you can query the database like this:

    var server = new MongoClient(new MongoUrl("mongodb://localhost:27017")).GetServer();
    var db = server.GetDatabase("myDatabase");
    var collection = db.GetCollection("myCollection");
    collection.FindAll().Dump();

  2. 1,132 votes
    Vote

    We're glad you're here

    Please sign in to leave feedback

    Signed in as (Sign out)
    You have left! (?) (thinking…)
    How important is this to you?

    We're glad you're here

    Please sign in to leave feedback

    Signed in as (Sign out)
    Anonymous supported this idea  ·