Created
September 3, 2015 07:04
-
-
Save sdsdkkk/aeb8e0ec1d4f32a9fe1b to your computer and use it in GitHub Desktop.
Sample DB Migration with LHM
This file contains 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
class TestingLhm < ActiveRecord::Migration | |
def self.up | |
Lhm.change_table :rand_numbers do |t| | |
t.add_column :something, "INT(12)" | |
t.add_index :something | |
end | |
end | |
def self.down | |
Lhm.change_table :rand_numbers do |t| | |
t.remove_index :something | |
t.remove_column :something | |
end | |
end | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment