How can I run geo queries using C#
Something as simple as this:
db.restaurants.find({ location:
{ $geoWithin:
{ $centerSphere: [ [ -73.93414657, 40.82302903 ], 5 / 3963.2 ] } } })
Any ideas on how I can do this?
How can I run geo queries using C#
Something as simple as this:
db.restaurants.find({ location:
{ $geoWithin:
{ $centerSphere: [ [ -73.93414657, 40.82302903 ], 5 / 3963.2 ] } } })
Any ideas on how I can do this?
I got along, Here's how:
var filter = Builders<BsonDocument>.Filter.GeoWithinCenterSphere("location", -73.93414657, 40.82302903 ,5 / 3963.2);
var results = collection.Find(filter).toList();
Thanks