Created
December 18, 2009 21:24
-
-
Save matsimitsu/259770 to your computer and use it in GitHub Desktop.
something like this? (from mongo activerecord docs)
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
# multiple options; works fine | |
User.all(:age => [1,2,3]) | |
# >> [#<User age: 3>] | |
# using the $lt operator; works fine | |
User.all(:age => {'$lt' => 10}) | |
# >> [#<User age: 3>] | |
# combining multiple options with the $lt operator; fails. | |
User.all(:age => {'$lt' => 10, '$in' => [50]) | |
# >> nil |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment