Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 3949566
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 20, 20262026-05-20T01:30:31+00:00 2026-05-20T01:30:31+00:00

I have a rails project that uses mongodb, the issue i am having is

  • 0

I have a rails project that uses mongodb, the issue i am having is when i have records (documents) made from a previous model. (i’m gettin klass errors, just for the older records)

Is there a quick way to fix those mongodb documents the rails way, using some command.

Or is there a command i can run with mongoid for it to open the specific model up in mongo, then i can poke with the document manually (removing unneeded associations).

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-20T01:30:32+00:00Added an answer on May 20, 2026 at 1:30 am

    The concept of schema migration would need to exist in mongoid and I don’t think it does. If you have made simple changes like renaming or removing fields then you can easily do that with an update statement, but for anything more complicated you will need to write code.

    The code you will need to write will most likely need to go down to the driver level to alter the objects since the mapping layer is no longer compatible.

    In general you need to be careful when you make schema changes, in your objects, since the server doesn’t have that concept and can’t enforce them. It is ultimately up to your code, or the framework you are using, to maintain compatibility.

    This is generally an issue when you mapping system without doing batch upgrades to keep things at the same schema, from the mapping layer perspective.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a rails project that uses an old versions of the FlexImage plug-in
we are currently working on a rails project that uses i18n and we have
I have a Rails project that uses bundler. Many of the gems I'm included
I have a Rails 3 project that uses some java jar files. I'm putting
I have a Rails 2.3.5 project that uses the localization features of Rails. I
I have a project that uses Sinatra for static pages and Rails for the
I have a rails project that I would like to set up email notifications
In my rails project I have a presenter method that has a helper view
in a rails project i have to deal with lots of strings, that are
I'm using DataMapper in a Rails project, and have found that calling to_json on

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.