This is the last thing I can think of.
def self.down
execute 'ALTER TABLE threads DROP FOREIGN KEY user_id'
end
OLD ONE
They should work :)
remove_foreign_key :threads, { :column => :user_id }
or
remove_foreign_key('threads', 'user_id')
or
remove_foreign_key(:threads, :user_id)
Peter
source
share