Skip to content

Instantly share code, notes, and snippets.

@radar
Forked from anonymous/gist:2313
Created July 24, 2008 22:00
Show Gist options
  • Save radar/2316 to your computer and use it in GitHub Desktop.
Save radar/2316 to your computer and use it in GitHub Desktop.
class AddPriceToProduct < ActiveRecord::Migration
def self.up
add_column :products, :price, :decimal,
:precision => 8, :scale => 2, :default => 0
end
def self.down
remove_column :products, :price
end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment