As I've written in comment, you are receiving that error because of:
SQLite3::SQLException: table "employees" already exists
Which simply means you already have that column in your database. You can resolve that in few ways:
changing migration to modify instead of create:
class CreateEmployees < ActiveRecord::Migration def self.up add_column :employees, :name, :string (...) end end def self.down remove_column :employees, :name end end
add another migration which will drop whole table (obviously, that one should be with earlier timestamp than modifying one so table will be dropped first and then created again):
class RemoveEmployees < ActiveRecord::Migration def change drop_table :employees end end
drop table by hand from console, but that's not a very good option as you should learn to use migrations for altering your database, of course that w'd be the fastest one (if you know how to use console) and will make no harm if that's just some learning project, but still, you should learn good habits when you can.
You might also want to use newer syntax (AFAIK) def change
instead of self.up
and self.down
, less letters to type and less duplication ;)