Top "Mongoid" questions

Mongoid is the official Ruby Object-Document-Mapper (ODM) for MongoDB.

MongoID Data Type for TEXT

Whats the best option to use for MongoID data type for the regular MongoDB TEXT data type. Wondering why MongoID …

mongodb mongoid
"Not equal" named scope in rails with Mongoid

I have two models Content and ContentType. In Content model I can do: def get_all_content_except_poking_message …

ruby-on-rails mongodb model-view-controller mongoid has-scope
rails mongoid criteria find by association

I'm trying to find a record by associated username which is included in a belongs_to relation, but it's not …

ruby-on-rails ruby-on-rails-3 mongodb associations mongoid
How to get the resultant array from a Mongoid::Criteria without an "each" block

Our application uses ajax very heavily and as a result of this we have statements like var items = #{@items.to_…

arrays mongoid criteria
MongoDB with Mongoid in Rails - Geospatial Indexing

MongoDB has a very nice Geospatial Indexing feature. How can I use it in Rails with Mongoid?

ruby-on-rails ruby mongodb geolocation mongoid
mongoid query caching

Rails' ActiveRecord has a feature called Query Caching (ActiveRecord::QueryCache) which saves the result of SQL query for the life-span …

ruby ruby-on-rails-3 caching mongoid rack
Mongoid dependent :destroy vs :delete

When using Mongoid referenced reletions what's the diffrence between dependent detroy and dependent delete since in the docs it tells: :…

ruby-on-rails mongoid
Managing mongoid migrations

Can someone give me a short introduction to doing DB migrations in Rails using Mongoid? I'm particularly interested in lazy …

ruby-on-rails mongoid database-migration rails-migrations
Rails: Store JSON in MongoDB

I am getting multiple similar JSON object from a remote site and looking to store them in a local MongoDB. …

ruby-on-rails mongodb mongoid mongomapper
field_for and nested form with mongoid

Could somebody give me the working example of nested form using mongoid? My models: class Employee include Mongoid::Document field :…

ruby-on-rails ruby-on-rails-3 mongoid