There is an application on ruby on rails
schema.rb
ActiveRecord::Schema.define(version: 20170302072830) do create_table "stocks", force: :cascade do |t| t.string "name", null: false t.integer "unit_price", null: false t.integer "interest", null: false t.integer "duration", null: false t.datetime "created_at", null: false t.datetime "updated_at", null: false t.integer "user_id" t.index ["user_id"], name: "index_stocks_on_user_id", using: :btree end create_table "users", force: :cascade do |t| t.string "email", default: "", null: false t.string "encrypted_password", default: "", null: false t.string "username", default: "", null: false t.datetime "remember_created_at" t.integer "sign_in_count", default: 0, null: false t.datetime "current_sign_in_at" t.datetime "last_sign_in_at" t.string "current_sign_in_ip" t.string "last_sign_in_ip" t.datetime "created_at", null: false t.datetime "updated_at", null: false t.index ["email"], name: "index_users_on_email", unique: true, using: :btree end end There have been several migrations under development.
Migrating to Heroku heroku rake db: migrate
I get a log
And what about the duration field and its integer type? There was a type change from date to integer.
ALTER TABLE "stocks" ALTER COLUMN "duration" TYPE integer PG :: DatatypeMismatch: ERROR: column "duration"
Well, his clue does not tell me anything
HINT: You might need to specify "USING duration :: integer".

