Fixed bad column definition

This commit is contained in:
Dan Elbert 2016-03-10 18:03:20 -06:00
parent 238adc4b61
commit 5f20e04b79
2 changed files with 7 additions and 2 deletions

View File

@ -0,0 +1,5 @@
class ChangeAmountColumn < ActiveRecord::Migration
def change
change_column :usda_food_weights, :amount, :decimal, precision: 7, scale: 3
end
end

View File

@ -11,7 +11,7 @@
# #
# It's strongly recommended that you check this file into your version control system. # It's strongly recommended that you check this file into your version control system.
ActiveRecord::Schema.define(version: 20160309182253) do ActiveRecord::Schema.define(version: 20160311000203) do
create_table "ingredients", force: :cascade do |t| create_table "ingredients", force: :cascade do |t|
t.string "name" t.string "name"
@ -70,7 +70,7 @@ ActiveRecord::Schema.define(version: 20160309182253) do
create_table "usda_food_weights", force: :cascade do |t| create_table "usda_food_weights", force: :cascade do |t|
t.integer "usda_food_id", null: false t.integer "usda_food_id", null: false
t.decimal "amount", precision: 5, scale: 3 t.decimal "amount", precision: 7, scale: 3
t.string "description" t.string "description"
t.decimal "gram_weight", precision: 7, scale: 1 t.decimal "gram_weight", precision: 7, scale: 1
t.datetime "created_at", null: false t.datetime "created_at", null: false