Created
August 31, 2011 18:57
-
-
Save Phrogz/1184389 to your computer and use it in GitHub Desktop.
Sequel migration
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sequel.migration do | |
up do | |
create_table :customers do | |
primary_key :id | |
column :name, :varchar, size:60, null:false | |
column :organization, :varchar, size:60, null:false | |
column :email, :varchar, size:60 | |
column :subscribed, :boolean, default:false, null:false | |
column :extra_str, :varchar, size:60 | |
column :extra_int, :integer | |
end | |
end | |
down do | |
drop_table :customers | |
end | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Run the migration with
where
.
means "look in the current directory for migration files".