I transfer data between two activerecord connections, I have all my settings for the correct settings, so I can read from the Legacy :: Tablename and Tablename website and paste them into a new table.
The problem I have is my new model does not have all the attributes that are in the old model, so I get an "unknown attribute" when I try to create an entry in the new model through;
legacy_users = Legacy::User.all legacy_users.each do |legacy_user| User.create legacy_user.attributes end
however, if I try to remove the insult attribute, it still does not work, for example.
legacy_user.attributes.delete 'some_attribute'
Can anyone suggest any pointers?
source share