I am trying to migrate a Rails 3 app. I installed Rails v 5.1.5 using RVM. When trying db:migrate, I get the following.
rake aborted! StandardError: An error has occurred, all later migrations canceled:
Directly inheriting from ActiveRecord::Migration is not supported. Please specify the Rails release the migration was written for:
class SorceryCore < ActiveRecord::Migration[4.2]
Here is the Class Definition for Sorcerycore:
class SorceryCore < <%= migration_class_name %>
def change
create_table :<%= model_class_name.tableize %> do |t|
t.string :email, :null => false
t.string :crypted_password
t.string :salt
t.timestamps :null => false
end
add_index :<%= model_class_name.tableize %>, :email, unique: true
end
end