Created
November 14, 2012 12:29
-
-
Save luxerama/4071837 to your computer and use it in GitHub Desktop.
Mongoid Moped query in order to get the distance returned by geospacial MongoDB queries
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# This works as of Mongoid v3 | |
Model.collection.database.command(geoNear: "models", near: [50, 50]) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment